The example illustrates how to create a Neon project using the Neon Go SDK and to query the project's default database.
Follow the steps to run the example:
- Download the module's dependencies:
go mod download
- Export the Neon API key to the process environment:
export NEON_API_KEY=##YOU-API-KEY##
- Compile and run the application:
go run main.go
It's expected to see the current UTC timestamp printed to the stdout, for example:
current UTC timestamp from database: 2024-12-08 11:08:46.67138 +0000 UTC