Sourced
llms.txt
View Markdown

Projects ยท version 0.1.0

Update project settings

PATCH/api/projects/{projectId}

Rename a project, update its API display name, or archive it. Workspace transfer is intentionally not enabled until role and ownership rules are finalized.

Request

cURL
curl -X PATCH 'https://sourced.sh/api/projects/{projectId}' \
  -H 'Authorization: Bearer $SOURCED_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{}'
TypeScript
const response = await fetch("https://sourced.sh/api/projects/{projectId}", {
  method: "PATCH",
  headers: {
    Authorization: `Bearer ${process.env.SOURCED_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({}),
});
const data = await response.json();
Python
import os
import requests

response = requests.request(
    "PATCH",
    "https://sourced.sh/api/projects/{projectId}",
    headers={"Authorization": f"Bearer {os.environ['SOURCED_API_KEY']}"},
    json={},
)
data = response.json()

Parameters

Path parameters

NameTypeRequiredDescription
projectIdstringYesProject identifier.

Request body

Required.

application/json

Schema
ProjectUpdateInput:
  type: object
  properties:
    name: string
      New project display name.
    apiName: string
      API display name used in generated docs and SDK metadata.
    status: string enum created | active | archived
    archive: boolean
      Set true to archive the project.
    transferOrgId: string
      Reserved for future workspace transfer support; currently returns 501.

Responses

200

Updated project.

application/json

Schema
type: object
required: project
properties:
  project (required): Project
    Project:
      type: object
      required: id, name, createdAt
      properties:
        id (required): string
        name (required): string
        apiName: string
        mode: string enum flagship | stainless_compatible | custom | openapi | stainless_migration
          New writes use `flagship` or `stainless_compatible`; legacy `custom`, `openapi`, and `stainless_migration` records may still be returned.
        status: string enum created | active | archived
        createdAt (required): string
        updatedAt: string
        runCount: integer

401

403

404

501

Project transfer is not supported yet.

application/json

Schema
Error:
  type: object
  required: error
  properties:
    error (required): string
      Stable machine-readable error code.
    message: string
      Optional human-readable description.
Was this helpful?