Access Token Information

Use this endpoint to retrieve information about an OAuth 2.0 access token.

Methods:

Click a method to view its documentation

POST

DescriptionTOP

Make a POST to this endpoint to retrieve information about an OAuth 2.0 access token, including:

  • the API key linked to the token
  • the Constant Contact username associated with the token
  • the remaining amount of time that the token is valid for, in seconds

Headers

To provide the access token in a URL encoded request, set the below header, and provide "access_token" as the key and the unique access token as the value in the url encoded request.

Content-Type: application/x-www-form-urlencoded

You may also omit headers and append the access token to the query parameters of the URI you make the request to (access_token=xxxxx).

POST: https://oauth2.constantcontact.com/oauth2/tokeninfo.htm

Response CodesTOP

code

description

200

Request was successful

404

The token provided is invalid or has expired

405

Unsupported method, only POST is supported by this endpoint

406

Unsupported accept header value, must be application/json

415

Unsupported content-type in the header, use application/x-www-form-urlencoded

503

Internal server error occurred

StructureTOP

property

type(max length)

description

access_token

string

The access_token for which to retrieve information.

Response StructureTOP

property

type(max length)

description

client_id

string

The API key of the client used in generating the access_token.

expires_in

integer

The remaining amount of time in seconds for which the access_token is valid. Tokens are initially valid for 10 years (315359999 seconds).

user_name

string

The user name for the account associated with the access_token.

Example ResponseTOP

{
    "client_id":"abcde-123456789",
    "user_name":"user_name_of_the_account",
    "expires_in":285027367
}