outside the context of a Pulumi project.
Two options would be to use the Pulumi CLI to access the outputs of the desired project using a bash script or you could also use the Automation API. The latter seems possibly a better choice for you as you appear to want to do this in typsecript code.
No matter how you like to participate in developer communities, Pulumi wants to meet you there. If you want to meet other Pulumi users to share use-cases and best practices, contribute code or documentation, see us at an event, or just tell a story about something cool you did with Pulumi, you are part of our community.