4.5. Confirming authorization

The authorization resources must be confirmed before they become usable. This is done by creating a confirmation resource for the authorization.

Example 4.6. POST /connectapi/authorizations/{id}/confirmation

request body
    "authSecret": string

HTTP Status codes

201: Confirmation succeeded

400: Confirmation failed due to given JSON being malformed or authSecret left blank

404: Not confirmed. Request failed. Either wrong authSecret was supplied or authorization resource does not exist

Table 4.3. Parameters

authSecretStringmThe secret value provided to the Paytrail account owner via SMS to authorize requested access.

Example 4.7. Example HTTP Request

POST /connectapi/authorizations/AXJD28237XSDHJS18928/confirmation HTTP/1.1
Timestamp: 2012-12-31T12:00:00+02:00
Content-MD5: ubewX5M7uzz64zskr7FThQ==
Authorization: PaytrailConnectAPI 13466:/YT5YGOUA17wK6qSeyQyrLqcGsUKflRkeWu/2q7NI2g=

    "authSecret": "1234"

Example 4.8. Example HTTP Response

HTTP/1.1 201 Created