Skip to content

Register an application

POST
/v1/developer/applications
curl --request POST \
--url https://api.trustysweep.com/v1/developer/applications \
--header 'Content-Type: application/json' \
--cookie sweep_session=<sweep_session> \
--data '{ "org_id": "org_01J8Z3K9M2Q4R6S8T0V2W4X6Y8", "name": "example", "description": "example", "homepage_url": "https://example.com", "privacy_url": "https://example.com", "redirect_uris": [ "https://example.com" ], "allowed_operations": [ "discover" ] }'
Idempotency-Key
string
<= 255 characters

Unique key per logical operation. Same key + same body within 24h replays the original response with Idempotent-Replayed: true; same key + different body → 409 idempotency_key_reused.

Media typeapplication/json
object
org_id
required

Prefixed ULID (org_…)

string
/^org_[0-9A-HJKMNP-TV-Z]{26}$/
name
required
string
>= 2 characters <= 80 characters
description
string
<= 500 characters
homepage_url
string format: uri
privacy_url
string format: uri
redirect_uris
Array<string>
allowed_operations
Array<string>
Allowed values: discover preserve write remove restore migrate monitor automate billable_execute

Created

Media typeapplication/json
object
id
required

Prefixed ULID (app_…)

string
/^app_[0-9A-HJKMNP-TV-Z]{26}$/
org_id
required

Prefixed ULID (org_…)

string
/^org_[0-9A-HJKMNP-TV-Z]{26}$/
name
required
string
description
One of:
string
homepage_url
One of:
string
privacy_url
One of:
string
redirect_uris
required
Array<string>
allowed_operations
required
Array<string>
Allowed values: discover preserve write remove restore migrate monitor automate billable_execute
status
required
string
Allowed values: active suspended deleted
created_at
required
string format: date-time
updated_at
required
string format: date-time
Example
{
"id": "app_01J8Z3K9M2Q4R6S8T0V2W4X6Y8",
"org_id": "org_01J8Z3K9M2Q4R6S8T0V2W4X6Y8",
"allowed_operations": [
"discover"
],
"status": "active"
}
RateLimit-Limit
integer

Requests allowed in the current window.

RateLimit-Remaining
integer

Requests remaining in the current window.

RateLimit-Reset
integer

Seconds until the window resets.

Validation failed

Media typeapplication/problem+json

RFC 9457 problem details.

object
type
required
title
required
string
status
required
integer
detail
string
code
required

Machine-readable error code from errors.json

string
request_id
required
string
errors
Array<object>
object
path
required
string
message
required
string
Examplegenerated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"path": "example",
"message": "example"
}
]
}

Unauthenticated

Media typeapplication/problem+json

RFC 9457 problem details.

object
type
required
title
required
string
status
required
integer
detail
string
code
required

Machine-readable error code from errors.json

string
request_id
required
string
errors
Array<object>
object
path
required
string
message
required
string
Examplegenerated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"path": "example",
"message": "example"
}
]
}

Forbidden / action denied / step-up required

Media typeapplication/problem+json

RFC 9457 problem details.

object
type
required
title
required
string
status
required
integer
detail
string
code
required

Machine-readable error code from errors.json

string
request_id
required
string
errors
Array<object>
object
path
required
string
message
required
string
Examplegenerated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"path": "example",
"message": "example"
}
]
}

Not found

Media typeapplication/problem+json

RFC 9457 problem details.

object
type
required
title
required
string
status
required
integer
detail
string
code
required

Machine-readable error code from errors.json

string
request_id
required
string
errors
Array<object>
object
path
required
string
message
required
string
Examplegenerated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"path": "example",
"message": "example"
}
]
}

Conflict (state, stale plan, idempotency key reuse)

Media typeapplication/problem+json

RFC 9457 problem details.

object
type
required
title
required
string
status
required
integer
detail
string
code
required

Machine-readable error code from errors.json

string
request_id
required
string
errors
Array<object>
object
path
required
string
message
required
string
Examplegenerated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"path": "example",
"message": "example"
}
]
}

Rate limited

Media typeapplication/problem+json

RFC 9457 problem details.

object
type
required
title
required
string
status
required
integer
detail
string
code
required

Machine-readable error code from errors.json

string
request_id
required
string
errors
Array<object>
object
path
required
string
message
required
string
Examplegenerated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"path": "example",
"message": "example"
}
]
}
Retry-After
integer

Seconds to wait before retrying.

RateLimit-Limit
integer

Requests allowed in the current window.

RateLimit-Remaining
integer

Requests remaining in the current window.

RateLimit-Reset
integer

Seconds until the window resets.

Internal error

Media typeapplication/problem+json

RFC 9457 problem details.

object
type
required
title
required
string
status
required
integer
detail
string
code
required

Machine-readable error code from errors.json

string
request_id
required
string
errors
Array<object>
object
path
required
string
message
required
string
Examplegenerated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"code": "example",
"request_id": "example",
"errors": [
{
"path": "example",
"message": "example"
}
]
}