Reset API key
Profiles API

POST
https://api.mollie.nl/v1/profiles/id/apikeys/mode
Authentication: OAuth access tokens

You can reset the API keys, for instance when you feel your keys may have been compromised. Please note the old API key can no longer be used once it has been reset.

Parameters

Replace id in the endpoint URL by the payment profile's ID, and replace mode by either live or test. For example: /v1/profiles/pfl_v9hTwCvYqw/apikeys/live.

Includes

Some endpoints allow you to indicate if you want more information to be included in the API response via the include querystring parameter.

  • No includes supported for this endpoint.

Response

200
application/json; charset=utf-8
resource
string

Indicates the response contains an API key object.

Possible values: profile_api_key

id
string

The (unchanged) API key's identifier.

Possible values: live test

key
string

The newly generated API key, which immediately replaces the previous API key.

createdDatetime
datetime

The API key's date and time of creation, in ISO 8601 format.

Example

Request code

// Not implemented. Create a pull request: https://github.com/mollie/mollie-api-php

Response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8

{
    "resource": "profile_api_key",
    "id": "live",
    "key": "live_QW7fVwCKzZZkxUsVwt39R2egTEf5Db",
    "createdDatetime": "2017-12-16T06:32:41.0Z"
}