Overview
Formal provides SDKs for programmatic access to the platform. Use SDKs to build custom tools, automation, and integrations.For most infrastructure management tasks, use the Terraform
provider instead of SDKs.
Official SDKs
The official Formal SDK for Go is available:Features
- Create, read, update, delete Formal objects
- Query logs and sessions programmatically
- Manage policies dynamically
- Integrate Formal into CI/CD pipelines
- Build custom dashboards and reports
Go Example
Install the SDK:https://api.formal.ai by default.
HTTP API
You can also call the API directly. It uses the Connect protocol, not REST. Every method is aPOST to https://api.formal.ai/<package>.<Service>/<Method> with a
JSON body.
Authentication
Example Requests
- List Resources
- Create User
- Query Logs
The API requires HTTP/2.
curl negotiates it automatically over HTTPS.
HTTP/1.1-only clients receive a 464 error.