Skip to content

Create a project

POST
/orgs/{org}/projects
curl --request POST \
--url https://api.sloose.com/orgs/org_9f3c/projects \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "name": "example", "description": "example", "visibility": "private", "config": { "additionalProperty": "example" }, "libraryVersions": "example", "expectedUpdatedAt": "example" }'

The configuration is migrated to the current schema version and validated before it is stored. Source rows are never stored — a project is the recipe, not the data.

org
required

The org id the session was issued for. A token for one org can never read another.

string
Example
org_9f3c

The org id the session was issued for. A token for one org can never read another.

Media typeapplication/json
object
name
required
string
>= 1 characters <= 200 characters
description
string | null
<= 2000 characters
visibility

private is the creator’s alone; org is visible to everyone in the org.

string
Allowed values: private org
config
required

The project configuration. Any schema version is accepted: it is migrated to the current one before it is stored, so an older client can still save.

object
key
additional properties
libraryVersions

Helper library versions this project was built against: namespace → semver.

object | null
expectedUpdatedAt

The updatedAt this client last read. Present: the write is refused with 409 if somebody else saved first. Absent: last writer wins.

string | null

Created.

Media typeapplication/json
object
project
required
object
id
required
string
orgId
required
string
connectorId
required

The destination this project imports into. Null means the org’s default CRM: a project from before connectors were named, or one saved by an API token or an older session, which name no connector.

string | null
name
required
string
description
required
string | null
createdByUserId
required
string
visibility
required
string
Allowed values: private org
schemaVersion
required
number
enabledModules
required
Array<string>
libraryVersions
required
object | null
registryVersion
required
number | null
sourceRef
required

bundle:<file> when pushed from a config repo; null when built by a person.

string | null
createdAt
required
string
updatedAt
required
string
config
required

Migrated to the current schema version on read. Null when it could not be migrated.

object | null
migrated
required

Migration steps applied on read. Non-empty means the stored row is from an older build.

Array<string>
unreadable
required
string | null
Example
{
"project": {
"visibility": "private"
}
}

The request body did not match the schema. issues carries the Zod issue list.

Media typeapplication/json

The error envelope every non-2xx answer uses.

object
error
required

Human-readable explanation.

string
code

Machine-readable reason. Absent on a few legacy 400s.

string
key
additional properties
Examplegenerated
{
"error": "example",
"code": "example"
}

No bearer, or one that is expired, revoked or no longer resolves to a member.

Media typeapplication/json

The error envelope every non-2xx answer uses.

object
error
required

Human-readable explanation.

string
code

Machine-readable reason. Absent on a few legacy 400s.

string
key
additional properties
Examplegenerated
{
"error": "example",
"code": "example"
}

The role is too low, the plan cannot share projects (code: FEATURE_SHARED_PROJECTS), or you are neither the creator nor an admin (code: NOT_PROJECT_OWNER).

Media typeapplication/json

The error envelope every non-2xx answer uses.

object
error
required

Human-readable explanation.

string
code

Machine-readable reason. Absent on a few legacy 400s.

string
key
additional properties
Examplegenerated
{
"error": "example",
"code": "example"
}

The configuration came from a newer build than this server (code: FROM_FUTURE).

Media typeapplication/json

The error envelope every non-2xx answer uses.

object
error
required

Human-readable explanation.

string
code

Machine-readable reason. Absent on a few legacy 400s.

string
key
additional properties
Examplegenerated
{
"error": "example",
"code": "example"
}

The configuration is not valid for the current schema version.

Media typeapplication/json
object
error
required
string
code
required
string
Allowed values: INVALID_PROJECT
issues
required
Array
key
additional properties
Example
{
"code": "INVALID_PROJECT"
}