On This Page

{#jumplink-list}  
[Markdown](/docs/vas/en-us/sis-pax/integration/all/rest/sis-pax/semi-integrated-solution-pax-get-started-intro/semi-integrated-solution-ad-app-activate-terminal-/semi-integrated-ad-app-activation-code-api-intro.md)  
Filter  
FILTER BY TAG

Generate a Terminal Activation Code Using a REST API Request {#semi-integrated-ad-app-activation-code-api-intro}
================================================================================================================

Before activating the terminal in the Acceptance Devices app, you must generate a terminal activation code.  
You can use a REST API request to generate a terminal activation code, which is valid for 24 hours.  
You must authenticate each request that you send to a `Visa Acceptance Solutions` API. In order to authenticate an API request, you can use a REST shared secret key or a REST certificate. For more information about authentication requirements, see the [*Getting Started with REST Developer Guide*](https://developer.visaacceptance.com/docs/vas/en-us/platform/developer/all/rest/rest-getting-started/restgs-intro.md "").

Endpoints
---------

The POST request must include the transacting merchant ID (MID) that is sending the request and the quantity of activation codes to be generated. You can request up to 15 activation codes in a single request.  
**Test:** `POST ``https://apitest.visaacceptance.com``/dms/v2/merchants/{transacting mid}/activation-codes?size={number of activation codes}`  
**Production:** `POST ``https://api.visaacceptance.com``/dms/v2/merchants/{transacting mid}/activation-codes?size={number of activation codes}`

Required Fields for Generating a Terminal Activation Code {#semi-integrated-ad-app-activation-code-api-reqfields}
=================================================================================================================

The body of the API request is empty. The POST request must include the information required to return the response.

REST Example: Generating a Terminal Activation Code {#semi-integrated-ad-app-activation-code-api-ex-rest}
=========================================================================================================

Request  
The body of the request is empty. The POST request includes the information required to return the response.

```
{
}
```

Response to a Successful Request  
The response includes the activation code (token field) and the amount of time (ttl field) that the activation code is valid. The ttl field value is shown in milliseconds. The activation code is valid for 24 hours.

```
{
    "tokens": [
        {
            "token": "%N5wU2jH",
            "ttl": 86399805
        }
    ]
}
```

RELATED TO THIS PAGE

