Launch Week 02 wrapped — explore all five launches

Create Project

POSThttps://api.confident-ai.com/v2/projects

Creates a project in your organization and provisions a project-scoped API key for it. The key's full value is returned once, in this response, and is redacted on every later read — so capture it here. The new project is seeded with Confident AI's default classifiers, online metric and trace alert, and pass email to assign an existing organization member as its Owner. How many projects you may hold depends on your plan, so this call can be refused on entitlement grounds even when the name is free.

POST/v2/projects
curl -X POST "https://api.confident-ai.com/v2/projects" \
  -H "CONFIDENT_API_KEY: <ORGANIZATION-API-KEY>" \
  -H "Content-Type: application/json" \
  -d '{
  "name": "Customer Support Agent",
  "description": "The support chatbot serving acme.com.",
  "email": "jane@acme.com"
}'
200
{
  "success": true,
  "data": {
    "project": {
      "id": "<PROJECT-ID>",
      "name": "Customer Support Agent",
      "description": "The support chatbot serving acme.com.",
      "organizationId": "<ORGANIZATION-ID>",
      "created_at": "2025-01-14T09:30:00.000Z"
    },
    "apiKey": {
      "id": 1041,
      "name": "Default Key",
      "valid": true,
      "value": "confident_us_proj_KZ0m8vQ2sVxT1bR4dYnJ6hLpA3wUcE9f",
      "shadowValue": null,
      "rotatesAt": null,
      "created_at": "2025-01-14T09:30:00.000Z",
      "lastUsed": null,
      "expiresAt": null
    }
  },
  "deprecated": false
}

Headers

  • CONFIDENT_API_KEYstringRequired

    The organization API key for your Confident AI organization.

Request body

  • namestringRequired

    The name of the project, which must not already be taken by another project in the organization.

  • descriptionstring

    What the project covers. Omit it to leave it unset.

  • emailstring

    The email of an existing member of your organization to assign as the project's Owner, which also attributes the provisioned API key to them. Omit it and the project has no member: it is reachable through its API key and to organization admins only.

Response

Create Project succeeded.

  • successboolean

    Indicates if the request was successful.

  • dataobject

    The created project and the API key provisioned with it. The key's value is not retrievable afterwards, so read it out of this response.

    Show 2 propertiesHide 2 properties
    • projectobject

      A project's own fields, without its governance enrollment. This is the shape create returns, where the project cannot yet be enrolled in a policy.

      Show 5 propertiesHide 5 properties
      • idstring

        The id of the project, generated by Confident AI.

      • namestring

        The name of the project, unique within the organization.

      • descriptionstring | null

        What the project covers, or null when it has no description.

      • organizationIdstring

        The id of the organization the project belongs to.

      • created_atstring

        When the project was created.

    • apiKeyobject | null

      The project-scoped API key provisioned alongside a new project, returned with its full value exactly once. This is the key an SDK config gets, and it is the credential the project's own data endpoints authenticate with — the organization key you created the project with cannot reach them.

      Show 9 propertiesHide 9 properties
      • idinteger

        The id of the API key, generated by Confident AI. Pass it as apiKeyId when deactivating or rotating the key.

      • namestring | null

        The label the key is listed under.

      • validboolean

        Whether the key is active. A deactivated key is rejected on authentication.

      • valuestring

        The full, unmasked key. This is the only response that ever carries it — every later read of this key redacts it to its last six characters — so store it now.

      • shadowValuestring | null

        The replacement value while a rotation's grace period is running. Always null on a freshly provisioned key, since nothing has been rotated yet.

      • rotatesAtstring | null

        When a pending rotation completes and shadowValue replaces value, or null when no rotation is pending.

      • created_atstring

        When the key was created.

      • lastUsedstring | null

        When the key was last used to authenticate, or null if it has never been used.

      • expiresAtstring | null

        When the key expires, or null if it never expires. A provisioned key never expires; create your own key with expiresInDays if you want one that does.

  • deprecatedboolean

    Indicates if this endpoint is deprecated.

Built byConfident AI