swagger: '2.0' info: version: 2020-08-01-preview title: Microsoft Azure AccessControlClient AccessConnector RefreshToken API schemes: - https tags: - name: RefreshToken paths: /oauth2/exchange: post: tags: - RefreshToken description: Exchange AAD tokens for an ACR refresh Token operationId: microsoftAzureGetacrrefreshtokenfromexchange consumes: - application/x-www-form-urlencoded parameters: - $ref: '#/parameters/Grant_type' - $ref: '#/parameters/Service' - $ref: '#/parameters/Tenant' - $ref: '#/parameters/RefreshToken' - $ref: '#/parameters/AccessToken' responses: '200': description: Refresh token acquired schema: $ref: '#/definitions/RefreshToken' default: description: ACR error response describing why the operation failed. schema: $ref: '#/definitions/AcrErrors' security: [] x-ms-examples: Exchange AAD Token for ACR Refresh: $ref: ./examples/PostRefreshToken.json summary: Microsoft Azure Post Oauth2 Exchange definitions: RefreshToken: type: object properties: refresh_token: description: The refresh token to be used for generating access tokens type: string AcrErrors: description: Acr error response describing why the operation failed properties: errors: type: array description: Array of detailed error items: $ref: '#/definitions/AcrErrorInfo' AcrErrorInfo: description: Error information properties: code: description: Error code type: string message: type: string description: Error message detail: type: object description: Error details parameters: RefreshToken: name: refresh_token in: formData required: false description: AAD refresh token, mandatory when grant_type is access_token_refresh_token or refresh_token type: string x-ms-parameter-location: method Grant_type: name: grant_type description: Can take a value of access_token_refresh_token, or access_token, or refresh_token type: string in: formData required: true enum: - access_token_refresh_token - access_token - refresh_token x-ms-parameter-location: method AccessToken: name: access_token in: formData required: false description: AAD access token, mandatory when grant_type is access_token_refresh_token or access_token. type: string x-ms-parameter-location: method Service: name: service in: formData required: true description: Indicates the name of your Azure container registry. type: string x-ms-parameter-location: method Tenant: name: tenant in: formData required: false description: AAD tenant associated to the AAD credentials. type: string x-ms-parameter-location: method x-ms-parameterized-host: hostTemplate: '{endpoint}' useSchemePrefix: false parameters: - $ref: '#/parameters/Endpoint'