{
  "opencollection": "1.0.0",
  "info": {
    "name": "Upsun.com Rest Add-ons API Tokens API",
    "version": "1.0"
  },
  "request": {
    "auth": {
      "type": "oauth2",
      "flow": "authorization_code",
      "authorizationUrl": "https://auth.api.platform.sh/oauth2/authorize",
      "accessTokenUrl": "https://auth.api.platform.sh/oauth2/token",
      "credentials": {
        "clientId": "{{clientId}}",
        "clientSecret": "{{clientSecret}}"
      }
    }
  },
  "items": [
    {
      "info": {
        "name": "API Tokens",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "List a user's API tokens",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "{schemes}://api.upsun.com/users/:user_id/api-tokens",
            "params": [
              {
                "name": "user_id",
                "value": "",
                "type": "path",
                "description": "The ID of the user."
              }
            ]
          },
          "docs": "Retrieves a list of API tokens associated with a single user."
        },
        {
          "info": {
            "name": "Create an API token",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "{schemes}://api.upsun.com/users/:user_id/api-tokens",
            "params": [
              {
                "name": "user_id",
                "value": "",
                "type": "path",
                "description": "The ID of the user."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Creates an API token"
        },
        {
          "info": {
            "name": "Get an API token",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "{schemes}://api.upsun.com/users/:user_id/api-tokens/:token_id",
            "params": [
              {
                "name": "user_id",
                "value": "",
                "type": "path",
                "description": "The ID of the user."
              },
              {
                "name": "token_id",
                "value": "",
                "type": "path",
                "description": "The ID of the token."
              }
            ]
          },
          "docs": "Retrieves the specified API token."
        },
        {
          "info": {
            "name": "Delete an API token",
            "type": "http"
          },
          "http": {
            "method": "DELETE",
            "url": "{schemes}://api.upsun.com/users/:user_id/api-tokens/:token_id",
            "params": [
              {
                "name": "user_id",
                "value": "",
                "type": "path",
                "description": "The ID of the user."
              },
              {
                "name": "token_id",
                "value": "",
                "type": "path",
                "description": "The ID of the token."
              }
            ]
          },
          "docs": "Deletes an API token"
        }
      ]
    }
  ],
  "bundled": true
}