{
"swagger": "2.0",
  "info": {
    "description": "Example endpoints for OAuth",
    "version": "1.0.0",
    "title": "Example OAuth"
  },
  "host":<<server>>,
  "basePath": "/o",
  "schemes": [
    "https"
  ],
  "paths": {
    "/token": {
      "post": {
        "summary": "Request a new Access Token",
        "description": "",
        "operationId": "getToken",
        "consumes": [
          "application/x-www-form-urlencoded"
        ],
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "in": "header",
            "name": "Authorization",
            "type": "string",
            "description": "The base 64 encoded client id/secret of the format: Basic {Base64Encode(client_id:client_secret)}",
            "required": true
          },
          {
            "in": "header",
            "name": "Content-Type",
            "type": "string",
            "description": "Value should be application/x-www-form-urlencoded",
            "required": true
          },
          {
            "in": "formData",
            "name": "grant_type",
            "type": "string",
            "description": "The grant type being requested (client_credentials)",
            "required": true
          }
        ],
        "responses": {
          "200": {
            "description": "Valid Response",
            "schema": {
              "type": "object",
              "properties": {
                "token": {
                  "type": "string",
                  "example": "a12d35da16d79731",
                  "description": "The access token"
                },
                "token_type": {
                  "type": "string",
                  "example": "Bearer",
                  "description": "The type of the token"
                },
                "expires_in": {
                  "type": "integer",
                  "example": 86400,
                  "description": "The time till expiry in seconds"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "schema": {
              "type": "object",
              "properties": {
                "description": {
                  "type": "string",
                  "example": "One or More request parameters was incorrect",
                  "description": "More detailed description of the problem"
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "schema": {
              "type": "object",
              "properties": {
                "description": {
                  "type": "string",
                  "example": "Invalid Client_Id/Client_Secret",
                  "description": "More detailed description of the problem"
                }
              }
            }
          }
        }
      }
    }
  }
}