Projects
A project is one product built on Agentpost. It belongs to one workspace, counts against the workspace’s project limit, and holds the services it adopted, its keys, and the address its email comes from. Its name is 1 to 120 characters, and its ID starts with prj_.
Make one project for each product. Two products in one project would share their principals, data, and keys; one product split across projects can’t share them. Every project has two environments, dev and prd, from the start.
Adopting a service
A project uses a service once it adopts it, with POST /v1/projects/{id}/services. The service then answers at its own path under https://api.agentpost.tools, such as /v1/identity, for the project’s keys, in both environments. A call to a service the project hasn’t adopted answers not_found. Adopting a service twice changes nothing. Create a project and issue a key adopts one.
Adopting a service writes its full starting config in both environments. The service’s config operation replaces the whole config; its reference says which fields may be left out, such as secrets the config doesn’t show.
Adopting services together also starts the connections their docs describe, such as automatic access history. Agentpost runs these connections for your project in each environment, including while your app is offline.
Keys
A project’s server calls its services with a secret key, and its browser or native app code starts a sign-in with a publishable key. Each key belongs to one project and one environment. A workspace key also reaches the project, read-only: it reads every project of its workspace that adopted the service its permissions read, one project per request.
A project’s email, such as sign-in codes, codes to add an email address, and invitations, comes from a domain it verified. Until one verifies, email to a real address isn’t sent: the request that would send it, such as asking for a sign-in code, answers as it always does, and no error says the email didn’t go. The test inbox holds email for tests. Set up a sending domain before the project emails real addresses.
A domain belongs to the first workspace that adds it; if verification fails and no project uses it as its sender, another workspace may add it. Remove the sending domain stops the project’s email until another domain verifies.
Lifetime
Only a workspace owner deletes a project. Deleting a project revokes its keys at once, gives its place back to the workspace’s limit, and can’t be undone. Agentpost tries to revoke its connected accounts’ tokens at their providers, then removes its service records in both environments even if a provider refused. The API waits up to 5 seconds for cleanup. If it answers with recordsRemoved: false, cleanup continues in the background or on the hourly sweep.
Where to act on it
- Create a project and issue a key creates a project and adopts a service, and Set up a sending domain verifies the domain its email comes from.
- Delete a project has the confirmation that deleting takes.
- The projects reference has every field.