API reference

API reference · Organizations

Create a project

POST/api/orgs/{id}/projectsSigned in session

Needs keys.manage; a budget at creation also needs members.budget. A project's monthly budget is a slice of the crew's balance: a request on one of its keys is refused (429 policy_exceeded) once the project's settled spend and holds this UTC month reach it, and a hold that would pass it is never placed. At most 100 live projects.

Parameters

Path and query parameters
FieldTypeWhat it is
id (path)requiredintegerThe crew's id.

Request body

application/json, required

Request body fields
FieldTypeWhat it is
namerequiredstring
budgetMicrosinteger or null

Example

{
  "name": "string",
  "budgetMicros": 0
}

Answer 201

Created.

Fields of the 201 answer
FieldTypeWhat it is
projectobject
project.idinteger
project.namestring
project.budgetMicrosinteger or null
project.dailyBudgetMicrosinteger or nullThe ceiling for one UTC day; null is none.
project.alertPctsarray of integerWhole percents of either ceiling at which project.budget_threshold goes to the webhooks of everyone who reads the crew's money, once per month or day.
project.createdAtinteger
project.archivedAtinteger or null
project.keyIdsarray of integer
project.spentMonthMicrosintegerThis UTC month's settled spend and holds. Billing readers only.
project.spentTodayMicrosintegerThis UTC day's settled spend and holds. Billing readers only.

Errors

  • 400OpenAI shaped error.
  • 401OpenAI shaped error.
  • 403OpenAI shaped error.
  • 404OpenAI shaped error.
  • 409OpenAI shaped error.

Every error answers in one shape, with its type, code and the field it names. The whole list is in the docs' Errors section.

Antimatter