{
  "opencollection": "1.0.0",
  "info": {
    "name": "Fence OpenAPI Specification admin/user credentials/cdis API",
    "version": "0.1.0"
  },
  "items": [
    {
      "info": {
        "name": "credentials/cdis",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "List API keys for user",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://example.domain/credentials/cdis",
            "auth": {
              "type": "oauth2",
              "flow": "authorization_code",
              "authorizationUrl": "/oauth/authorize",
              "accessTokenUrl": "/oauth/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "List all the API keys for the current user"
        },
        {
          "info": {
            "name": "Receive API key",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://example.domain/credentials/cdis",
            "auth": {
              "type": "oauth2",
              "flow": "authorization_code",
              "authorizationUrl": "/oauth/authorize",
              "accessTokenUrl": "/oauth/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Get a new API key for the current user. API keys can be used to retrieve access tokens which will allow for authed communication to our API."
        },
        {
          "info": {
            "name": "Delete user API key",
            "type": "http"
          },
          "http": {
            "method": "DELETE",
            "url": "https://example.domain/credentials/cdis/:key_id",
            "params": [
              {
                "name": "key_id",
                "value": "",
                "type": "path",
                "description": "API Key key_id/jti"
              }
            ],
            "auth": {
              "type": "oauth2",
              "flow": "authorization_code",
              "authorizationUrl": "/oauth/authorize",
              "accessTokenUrl": "/oauth/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Delete a API access key for the current user"
        },
        {
          "info": {
            "name": "Receive access token when given API key",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://example.domain/credentials/cdis/access_token",
            "body": {
              "type": "json",
              "data": "{}"
            },
            "auth": {
              "type": "oauth2",
              "flow": "authorization_code",
              "authorizationUrl": "/oauth/authorize",
              "accessTokenUrl": "/oauth/token",
              "credentials": {
                "clientId": "{{clientId}}",
                "clientSecret": "{{clientSecret}}"
              }
            }
          },
          "docs": "Get a new temporary access token for the current user by providing a valid API key."
        }
      ]
    }
  ],
  "bundled": true
}