curl -X GET "https://api.apitraffic.io/v1/accounts/acc_abc123def456ghi789jkl012/buckets" \
  -H "Authorization: Bearer your-jwt-token"
{
  "hasMore": false,
  "records": [
    {
      "sid": "bkt_xyz789uvw012rst345abc",
      "accountSid": "acc_abc123def456ghi789jkl012",
      "name": "Production API",
      "verifySslCerts": true,
      "appIsConnected": true,
      "createdAt": "2023-12-01T10:30:00.000Z"
    }
  ]
}

List Buckets

Retrieve all buckets associated with an account.

Path Parameters

accountSid
string
required
Account identifier (format: acc_ followed by 27 alphanumeric characters)

Headers

Authorization
string
required
Bearer token for authentication

Response

hasMore
boolean
Indicates if there are more records to paginate through
records
array
curl -X GET "https://api.apitraffic.io/v1/accounts/acc_abc123def456ghi789jkl012/buckets" \
  -H "Authorization: Bearer your-jwt-token"
{
  "hasMore": false,
  "records": [
    {
      "sid": "bkt_xyz789uvw012rst345abc",
      "accountSid": "acc_abc123def456ghi789jkl012",
      "name": "Production API",
      "verifySslCerts": true,
      "appIsConnected": true,
      "createdAt": "2023-12-01T10:30:00.000Z"
    }
  ]
}

Get Bucket

Retrieve details of a specific bucket.

Path Parameters

accountSid
string
required
Account identifier
bucketSid
string
required
Bucket identifier

Headers

Authorization
string
required
Bearer token for authentication

Response

sid
string
Unique bucket identifier
accountSid
string
Account identifier this bucket belongs to
name
string
Name of the bucket
verifySslCerts
boolean
Whether SSL certificates should be verified as valid and trusted
appIsConnected
boolean
Whether the bucket is connected to an application via the SDK
createdAt
string
ISO 8601 timestamp of bucket creation
curl -X GET "https://api.apitraffic.io/v1/accounts/acc_abc123def456ghi789jkl012/buckets/bkt_xyz789uvw012rst345abc" \
  -H "Authorization: Bearer your-jwt-token"
{
  "sid": "bkt_xyz789uvw012rst345abc",
  "accountSid": "acc_abc123def456ghi789jkl012",
  "name": "Production API",
  "verifySslCerts": true,
  "appIsConnected": true,
  "createdAt": "2023-12-01T10:30:00.000Z"
}

Create Bucket

Create a new bucket for organizing API traffic data.

Path Parameters

accountSid
string
required
Account identifier

Headers

Authorization
string
required
Bearer token for authentication

Request Body

name
string
required
The name of the bucket

Response

Returns the created bucket object with the same structure as the Get Bucket response.
curl -X POST "https://api.apitraffic.io/v1/accounts/acc_abc123def456ghi789jkl012/buckets" \
  -H "Authorization: Bearer your-jwt-token" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Staging API"
  }'
{
  "sid": "bkt_new789uvw012rst345def",
  "accountSid": "acc_abc123def456ghi789jkl012",
  "name": "Staging API",
  "verifySslCerts": true,
  "appIsConnected": false,
  "createdAt": "2023-12-01T15:45:00.000Z"
}

Update Bucket

Update the details of an existing bucket.

Path Parameters

accountSid
string
required
Account identifier
bucketSid
string
required
Bucket identifier

Headers

Authorization
string
required
Bearer token for authentication

Request Body

name
string
required
The name of the bucket
verifySslCerts
boolean
required
Whether SSL certificates should be verified as valid and trusted

Response

Returns the updated bucket object.
curl -X PUT "https://api.apitraffic.io/v1/accounts/acc_abc123def456ghi789jkl012/buckets/bkt_xyz789uvw012rst345abc" \
  -H "Authorization: Bearer your-jwt-token" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Updated Production API",
    "verifySslCerts": false
  }'
{
  "sid": "bkt_xyz789uvw012rst345abc",
  "accountSid": "acc_abc123def456ghi789jkl012",
  "name": "Updated Production API",
  "verifySslCerts": false,
  "appIsConnected": true,
  "createdAt": "2023-12-01T10:30:00.000Z"
}

Delete Bucket

Delete a bucket and all associated requests.
This action is irreversible. All data associated with the bucket will be permanently deleted.

Path Parameters

accountSid
string
required
Account identifier
bucketSid
string
required
Bucket identifier

Headers

Authorization
string
required
Bearer token for authentication

Response

sid
string
ID of the deleted bucket
deleted
boolean
Flag indicating the bucket was successfully deleted
curl -X DELETE "https://api.apitraffic.io/v1/accounts/acc_abc123def456ghi789jkl012/buckets/bkt_xyz789uvw012rst345abc" \
  -H "Authorization: Bearer your-jwt-token"
{
  "sid": "bkt_xyz789uvw012rst345abc",
  "deleted": true
}

Get SDK Settings

Retrieve SDK settings for a bucket based on the ingestion key.

Path Parameters

bucketSid
string
required
Bucket identifier

Query Parameters

redactAt
string
required
Where data should be redacted. Must be either client or server
clientId
string
required
ID of the client attempting to get the SDK settings

Headers

Authorization
string
required
Bearer token for authentication

Response

Returns SDK configuration settings including redaction rules and exclusion patterns.
curl -X GET "https://api.apitraffic.io/v1/buckets/bkt_xyz789uvw012rst345abc/sdk?redactAt=client&clientId=client_123" \
  -H "Authorization: Bearer your-jwt-token"
{
  "redactionRules": [
    {
      "field": "password",
      "action": "redact"
    }
  ],
  "exclusionRules": [
    {
      "path": "/health",
      "method": "GET"
    }
  ],
  "settings": {
    "interceptOutbound": true,
    "debug": false
  }
}