Sending Arbitrary Parameters with Refresh Token API Calls

Overview

This article explains how to send custom parameters with POST /oauth/token API calls when using a refresh token and how to access those parameters in Rules.



Applies To

  • Refresh Token
  • API Calls
  • Parameters

Solution

Custom parameters can be sent in the body of the /oauth/token API call during the Refresh Token flow. These parameters are then accessible in the Rules.

  1. A standard Refresh Token API call body includes the following parameters:

    grant_type: 'refresh_token',
    client_id: '...',
    client_secret: '...',
    refresh_token: '...'
    
    
  2. To add a custom parameter, include it in the body of the call as shown in the example below:

    grant_type: 'refresh_token',
    client_id: '...',
    client_secret: '...',
    refresh_token: '...',
    custom_param: 'some value'
    
    

NOTE: A best practice is to namespace custom parameters to prevent collisions with future parameters. For example, use a prefix such as <company_name>_param.

 


 

Recommended content

No recommended content found...