Enable voucher issuer

Profiles API v2
POSThttps://api.mollie.com/v2/profiles/*id*/methods/voucher/issuers/*issuer*
POSThttps://api.mollie.com/v2/profiles/me/methods/voucher/issuers/*issuer*
Authentication:API keys

Enable a voucher issuer on a specific or authenticated profile to use it with payments.

Parameters

Replace id in the endpoint URL by the profile’s ID, for example pfl_v9hTwCvYqw and issuer with the identifier of the issuer you want to activate, for example appetiz.

contractIdstringoptional
The contract id of the related contractor. For the first call that will be made to an issuer of the contractor, this field is required. You do not have to provide the same contract id for other issuers of the same contractor. Update of the contract ID will be possible through making the same call again with different contract ID value until the contract id is approved by the contractor.

Response

201 application/hal+json

resourcestring
Indicates the response contains an issuer object. Will always contain issuer for this endpoint.
idstring
The unique identifier of the voucher issuer.
descriptionstring
The full name of the voucher issuer.
statusstring

The status that the issuer is in. Possible values: pending-issuer or activated.

  • activated The issuer is activated and ready for use.
  • pending-issuer Activation of this issuer relies on you taking action with the issuer itself.
contractorobject

An object with contractor information.

Show child parameters

idstring
namestring
contractIdstring
_linksobject

An object with several URL objects relevant to the voucher issuer. Every URL object will contain an href and a type field.

Show child parameters

selfURL object
The API resource URL of the voucher issuer itself.
documentationURL object
The URL to the voucher issuer retrieval endpoint documentation.

Example

Request

cURLPHPPythonRubyNode.js
1
2
3
4
curl -X POST https://api.mollie.com/v2/profiles/pfl_v9hTwCvYqw/methods/voucher/issuers/appetiz \
     -H "Authorization: Bearer access_Wwvu7egPcJLLJ9Kb7J632x8wJ2zMeJ" \
     -H "Content-Type: application/json" \
     --data-raw '{ "contractId": "abc123" }'
1
2
3
4
5
6
7
from mollie.api.client import Client

mollie_client = Client()
mollie_client.set_access_token("access_Wwvu7egPcJLLJ9Kb7J632x8wJ2zMeJ")

profile = mollie_client.profiles.get("pfl_v9hTwCvYqw")
issuer = profile.methods.enable_issuer("voucher", "appetiz", {"contractId": "abc123"})
1
2
3
4
We don't have a PHP code example for this API call yet.

If you have some time to spare, feel free to share suggestions on our Discord:
https://discord.gg/VaTVkXB4aQ
1
2
3
4
We don't have a Ruby code example for this API call yet.

If you have some time to spare, feel free to share suggestions on our Discord:
https://discord.gg/VaTVkXB4aQ
1
2
3
4
We don't have a Node.js code example for this API call yet.

If you have some time to spare, feel free to share suggestions on our Discord:
https://discord.gg/VaTVkXB4aQ

Response

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
HTTP/1.1 201 Created
Content-Type: application/hal+json; charset=utf-8

 {
     "resource": "issuer",
     "id": "appetiz",
     "description": "Appetiz",
     "status": "pending-issuer",
     "contractor": {
         "id": "Conecs",
         "name": "Conecs",
         "contractId": "abc123"
     },
     "image": {
         "size1x": "https://www.mollie.com/external/icons/voucher-issuers/apetiz.png",
         "size2x": "https://www.mollie.com/external/icons/voucher-issuers/apetiz%402x.png",
         "svg": "https://www.mollie.com/external/icons/voucher-issuers/apetiz.svg"
     },
     "_links": {
         "self": {
             "href": "https://api.mollie.com/v2/issuers/appetiz",
             "type": "application/hal+json"
         },
         "documentation": {
             "href": "https://docs.mollie.com/reference/v2/profiles-api/enable-voucher-issuer",
             "type": "text/html"
         }
     }
 }