Skip to main content
Contents

Reseller API

Users of a reseller, their limits and their usage periods. Served on the Reseller API host with the reseller API key.

Literal response from the frozen contract

GET/users

List users

Returns every user of the reseller.

The api_key field of each user is empty by default: keys are no longer stored in a readable form.

Authentication
HTTP Basic with the reseller API key
Host
https://reseller.cdnify.lat
In CDNify
Same behaviour as before
API v2 equivalent

Responses

  • 200OKapplication/json

    Fields (15)
    Responses resellerListUsers 200
    FieldTypeRequiredRules
    usersarray<object>Yes
    users[].idstringYes
    • Pattern: ^u[0-9a-f]{9}$
    users[].emailstringYes
    users[].api_keystringYes
    users[].createdstringYes
    users[].accounting_idstringYes
    users[].bandwidth_usagestring | numberYes
    users[].bandwidth_limitstring | numberYes
    users[].resource_limitinteger | stringYes
    users[].customstringYes
    • Can be null
    users[].reset_intervalinteger | stringYes
    users[].usage_periodintegerYes
    users[].last_reset_datestringYes
    users[].next_reset_datestringYes
    • Can be null
    users[].rolesarray<string>Yes
    Example
    {
      "users": [
        {
          "id": "u0a1b2c3d4",
          "email": "customer@example.com",
          "api_key": "SYNTHETIC-USER-API-KEY-0000000000000000000000000000",
          "created": "2026-01-15T10:00:00+00:00",
          "accounting_id": "ACC-1001",
          "bandwidth_usage": "12.50000",
          "bandwidth_limit": "100",
          "resource_limit": 5,
          "custom": null,
          "reset_interval": 30,
          "usage_period": 3,
          "last_reset_date": "2026-01-01T00:00:00+00:00",
          "next_reset_date": "2026-01-31T00:00:00+00:00",
          "roles": [
            "ROLE_USER"
          ]
        }
      ]
    }
  • 401Unauthorized

    Headers: WWW-Authenticate: Basic realm="Secured Area"

curl
curl 'https://reseller.cdnify.lat/users' \
  -u "$CDNIFY_RESELLER_API_KEY:x"
POST/users

Create a user

Creates a user of the reseller with its limits. The answer includes the new user's API key.

Authentication
HTTP Basic with the reseller API key
Host
https://reseller.cdnify.lat
In CDNify
Same behaviour as before
API v2 equivalent

Request body

Content types: application/x-www-form-urlencoded

Request body resellerCreateUser
FieldTypeRequiredRules
emailstringYes
  • Format: email
passwordstringYes
  • At least 1 characters
reset_intervalinteger | stringNo
resource_limitinteger | stringNo
  • Minimum 0
bandwidth_limitnumber | stringNo
  • Minimum 0
accounting_idstringNo
customstringNo
Example
{
  "email": "customer@example.com",
  "password": "synthetic-password",
  "bandwidth_limit": 100,
  "resource_limit": 5,
  "reset_interval": 30,
  "accounting_id": "ACC-1001"
}

Responses

  • 201Createdapplication/json

    Fields (15)
    Responses resellerCreateUser 201
    FieldTypeRequiredRules
    usersarray<object>Yes
    users[].idstringYes
    • Pattern: ^u[0-9a-f]{9}$
    users[].emailstringYes
    users[].api_keystringYes
    users[].createdstringYes
    users[].accounting_idstringYes
    users[].bandwidth_usagestring | numberYes
    users[].bandwidth_limitstring | numberYes
    users[].resource_limitinteger | stringYes
    users[].customstringYes
    • Can be null
    users[].reset_intervalinteger | stringYes
    users[].usage_periodintegerYes
    users[].last_reset_datestringYes
    users[].next_reset_datestringYes
    • Can be null
    users[].rolesarray<string>Yes
    Example
    {
      "users": [
        {
          "id": "u0a1b2c3d4",
          "email": "customer@example.com",
          "api_key": "SYNTHETIC-USER-API-KEY-0000000000000000000000000000",
          "created": "2026-01-15T10:00:00+00:00",
          "accounting_id": "ACC-1001",
          "bandwidth_usage": 0,
          "bandwidth_limit": "100",
          "resource_limit": "5",
          "custom": null,
          "reset_interval": "30",
          "usage_period": 0,
          "last_reset_date": "2026-01-01T00:00:00+00:00",
          "next_reset_date": "2026-01-31T00:00:00+00:00",
          "roles": [
            "ROLE_USER"
          ]
        }
      ]
    }
  • 400Bad requestapplication/json

    Fields (2)
    Responses resellerCreateUser 400
    FieldTypeRequiredRules
    usersarrayYes
    • At most 0 items
    errorstringYes
    Example: email
    {
      "users": [],
      "error": "Invalid user email address"
    }
    Example: password
    {
      "users": [],
      "error": "Invalid password"
    }
    Example: duplicate
    {
      "users": [],
      "error": "Duplicate email address"
    }
    Example: bandwidth
    {
      "users": [],
      "error": "Invalid bandwidth limit"
    }
    Example: resources
    {
      "users": [],
      "error": "Invalid resource limit"
    }
  • 401Unauthorized

    Headers: WWW-Authenticate: Basic realm="Secured Area"

curl
curl -X POST 'https://reseller.cdnify.lat/users' \
  -u "$CDNIFY_RESELLER_API_KEY:x" \
  --data-urlencode 'email=customer@example.com' \
  --data-urlencode 'password=synthetic-password' \
  --data-urlencode 'bandwidth_limit=100' \
  --data-urlencode 'resource_limit=5' \
  --data-urlencode 'reset_interval=30' \
  --data-urlencode 'accounting_id=ACC-1001'
GET/users/{user}

Get a user

Returns one user, by ID or by e-mail address.

The api_key field is empty by default: keys are no longer stored in a readable form.

Authentication
HTTP Basic with the reseller API key
Host
https://reseller.cdnify.lat
In CDNify
Same behaviour as before
API v2 equivalent

Parameters

Parameters resellerGetUser
NameInTypeRequiredRules
userPathstringYes
emailQuerystringNo

Responses

  • 200OKapplication/json

    Fields (15)
    Responses resellerGetUser 200
    FieldTypeRequiredRules
    usersarray<object>Yes
    users[].idstringYes
    • Pattern: ^u[0-9a-f]{9}$
    users[].emailstringYes
    users[].api_keystringYes
    users[].createdstringYes
    users[].accounting_idstringYes
    users[].bandwidth_usagestring | numberYes
    users[].bandwidth_limitstring | numberYes
    users[].resource_limitinteger | stringYes
    users[].customstringYes
    • Can be null
    users[].reset_intervalinteger | stringYes
    users[].usage_periodintegerYes
    users[].last_reset_datestringYes
    users[].next_reset_datestringYes
    • Can be null
    users[].rolesarray<string>Yes
    Example
    {
      "users": [
        {
          "id": "u0a1b2c3d4",
          "email": "customer@example.com",
          "api_key": "SYNTHETIC-USER-API-KEY-0000000000000000000000000000",
          "created": "2026-01-15T10:00:00+00:00",
          "accounting_id": "ACC-1001",
          "bandwidth_usage": "12.50000",
          "bandwidth_limit": "100",
          "resource_limit": 5,
          "custom": null,
          "reset_interval": 30,
          "usage_period": 3,
          "last_reset_date": "2026-01-01T00:00:00+00:00",
          "next_reset_date": "2026-01-31T00:00:00+00:00",
          "roles": [
            "ROLE_USER"
          ]
        }
      ]
    }
  • 401Unauthorized

    Headers: WWW-Authenticate: Basic realm="Secured Area"

  • 404Not foundapplication/json

    Example
    []
curl
curl 'https://reseller.cdnify.lat/users/u0a1b2c3d4' \
  -u "$CDNIFY_RESELLER_API_KEY:x"
PATCH/users/{user}

Update a user

Changes the e-mail address, limits or reset interval of a user.

Authentication
HTTP Basic with the reseller API key
Host
https://reseller.cdnify.lat
In CDNify
Same contract, with a defect corrected
API v2 equivalent
No API v2 equivalent

Parameters

Parameters resellerUpdateUser
NameInTypeRequiredRules
userPathstringYes

Request body

Content types: application/x-www-form-urlencoded

Request body resellerUpdateUser
FieldTypeRequiredRules
passwordstringNo
reset_intervalinteger | stringNo
resource_limitinteger | stringNo
bandwidth_limitnumber | stringNo
accounting_idstringNo
customstringNo
Example
{
  "bandwidth_limit": 250
}

Responses

  • 200OKapplication/json

    Fields (15)
    Responses resellerUpdateUser 200
    FieldTypeRequiredRules
    usersarray<object>Yes
    users[].idstringYes
    • Pattern: ^u[0-9a-f]{9}$
    users[].emailstringYes
    users[].api_keystringYes
    users[].createdstringYes
    users[].accounting_idstringYes
    users[].bandwidth_usagestring | numberYes
    users[].bandwidth_limitstring | numberYes
    users[].resource_limitinteger | stringYes
    users[].customstringYes
    • Can be null
    users[].reset_intervalinteger | stringYes
    users[].usage_periodintegerYes
    users[].last_reset_datestringYes
    users[].next_reset_datestringYes
    • Can be null
    users[].rolesarray<string>Yes
    Example
    {
      "users": [
        {
          "id": "u0a1b2c3d4",
          "email": "customer@example.com",
          "api_key": "SYNTHETIC-USER-API-KEY-0000000000000000000000000000",
          "created": "2026-01-15T10:00:00+00:00",
          "accounting_id": "ACC-1001",
          "bandwidth_usage": "12.50000",
          "bandwidth_limit": "250",
          "resource_limit": 5,
          "custom": null,
          "reset_interval": 30,
          "usage_period": 3,
          "last_reset_date": "2026-01-01T00:00:00+00:00",
          "next_reset_date": "2026-01-31T00:00:00+00:00",
          "roles": [
            "ROLE_USER"
          ]
        }
      ]
    }
  • 401Unauthorized

    Headers: WWW-Authenticate: Basic realm="Secured Area"

  • 404Not foundapplication/json

    Example
    []
  • 500Internal server errortext/html

curl
curl -X PATCH 'https://reseller.cdnify.lat/users/u0a1b2c3d4' \
  -u "$CDNIFY_RESELLER_API_KEY:x" \
  --data-urlencode 'bandwidth_limit=250'
DELETE/users/{user}

Delete a user

Deletes a user of the reseller.

Authentication
HTTP Basic with the reseller API key
Host
https://reseller.cdnify.lat
In CDNify
Same behaviour as before
API v2 equivalent
No API v2 equivalent

Parameters

Parameters resellerDeleteUser
NameInTypeRequiredRules
userPathstringYes

Responses

  • 204No content

  • 401Unauthorized

    Headers: WWW-Authenticate: Basic realm="Secured Area"

curl
curl -X DELETE 'https://reseller.cdnify.lat/users/u0a1b2c3d4' \
  -u "$CDNIFY_RESELLER_API_KEY:x"
GET/users/{user}/bandwidth_history

Bandwidth history of a user

Returns the usage periods of a user with the bandwidth of each one.

Authentication
HTTP Basic with the reseller API key
Host
https://reseller.cdnify.lat
In CDNify
Same behaviour as before
API v2 equivalent

Parameters

Parameters resellerGetBandwidthHistory
NameInTypeRequiredRules
userPathstringYes

Responses

  • 200OKapplication/json

    Fields (7)
    Responses resellerGetBandwidthHistory 200
    FieldTypeRequiredRules
    historyarray<object>Yes
    history[].usage_periodintegerYes
    history[].startstringYes
    history[].endstringYes
    history[].limitstring | numberYes
    history[].usagestring | numberYes
    history[].customstringYes
    • Can be null
    Example
    {
      "history": [
        {
          "usage_period": 2,
          "start": "2025-12-01T00:00:00+00:00",
          "end": "2026-01-01T00:00:00+00:00",
          "limit": "100.00000",
          "usage": "37.25000",
          "custom": null
        }
      ]
    }
  • 401Unauthorized

    Headers: WWW-Authenticate: Basic realm="Secured Area"

  • 404Not foundapplication/json

    Example
    []
curl
curl 'https://reseller.cdnify.lat/users/u0a1b2c3d4/bandwidth_history' \
  -u "$CDNIFY_RESELLER_API_KEY:x"
POST/users/{user}/reset_usage

Reset the usage of a user

Closes the current usage period of a user and starts a new one at zero.

Authentication
HTTP Basic with the reseller API key
Host
https://reseller.cdnify.lat
In CDNify
Same behaviour as before
API v2 equivalent
No API v2 equivalent

Parameters

Parameters resellerResetUsage
NameInTypeRequiredRules
userPathstringYes

Responses

  • 200OKapplication/json

    Fields (15)
    Responses resellerResetUsage 200
    FieldTypeRequiredRules
    usersarray<object>Yes
    users[].idstringYes
    • Pattern: ^u[0-9a-f]{9}$
    users[].emailstringYes
    users[].api_keystringYes
    users[].createdstringYes
    users[].accounting_idstringYes
    users[].bandwidth_usagestring | numberYes
    users[].bandwidth_limitstring | numberYes
    users[].resource_limitinteger | stringYes
    users[].customstringYes
    • Can be null
    users[].reset_intervalinteger | stringYes
    users[].usage_periodintegerYes
    users[].last_reset_datestringYes
    users[].next_reset_datestringYes
    • Can be null
    users[].rolesarray<string>Yes
    Example
    {
      "users": [
        {
          "id": "u0a1b2c3d4",
          "email": "customer@example.com",
          "api_key": "SYNTHETIC-USER-API-KEY-0000000000000000000000000000",
          "created": "2026-01-15T10:00:00+00:00",
          "accounting_id": "ACC-1001",
          "bandwidth_usage": 0,
          "bandwidth_limit": "100",
          "resource_limit": 5,
          "custom": null,
          "reset_interval": 30,
          "usage_period": 4,
          "last_reset_date": "2026-01-01T00:00:00+00:00",
          "next_reset_date": "2026-01-31T00:00:00+00:00",
          "roles": [
            "ROLE_USER"
          ]
        }
      ]
    }
  • 401Unauthorized

    Headers: WWW-Authenticate: Basic realm="Secured Area"

  • 404Not foundapplication/json

    Example
    []
curl
curl -X POST 'https://reseller.cdnify.lat/users/u0a1b2c3d4/reset_usage' \
  -u "$CDNIFY_RESELLER_API_KEY:x"