curl --request POST \
--url https://api.stage.localpayment.com/api/payin/subscriptions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"paymentMethod": {
"type": "CreditCard",
"code": "1000",
"flow": "DIRECT"
},
"externalId": "820d6e89-3715-4296-9975-def5c7750f65",
"country": "ARG",
"amount": 100,
"currency": "ARS",
"accountNumber": "{{accountNumber}}",
"conceptCode": "0001",
"comment": "Test",
"merchant": {
"type": "COMPANY",
"name": "Company",
"document": {
"type": "DNI",
"id": "12345678"
},
"userReference": "abc123",
"email": "merchant@mail.com",
"phone": {
"countryCode": "54",
"areaCode": "11",
"number": "98781234"
}
},
"payer": {
"type": "INDIVIDUAL",
"name": "John",
"lastname": "Doe",
"document": {
"id": "37993812",
"type": "DNI"
},
"email": "john.doe@example.com",
"phone": {
"countryCode": "1",
"areaCode": "11",
"number": "98789123"
}
},
"card": {
"name": "APRO",
"number": "4000000000000002",
"cvv": "123",
"expirationMonth": "11",
"expirationYear": "2029",
"installments": 1
},
"type": "SOFTWARE",
"autoRecurring": {
"type": "day"
}
}
'
{
"subscriptionId": "133640f9-ac16-49fc-aa82-08bfe52ceb5e",
"status": {
"code": "105",
"description": "INPROGRESS",
"detail": "The subscription is in progress"
},
"creationDate": "2024-05-31T15:05:47.665+00:00",
"nextPaymentDate": "2024-06-30T15:05:47.665+00:00",
"payments": [
{
"externalId": "bb7d3235-04da-4b8a-85bf-8caf89d986ea",
"internalId": "9977c453-ce00-48fd-baac-f685bce30895",
"status": {
"code": "103",
"description": "APPROVED",
"detail": "The payin was confirmed but not credited yet"
}
}
]
}
Abbonamenti
Creare un abbonamento
POST
/
api
/
payin
/
subscriptions
curl --request POST \
--url https://api.stage.localpayment.com/api/payin/subscriptions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"paymentMethod": {
"type": "CreditCard",
"code": "1000",
"flow": "DIRECT"
},
"externalId": "820d6e89-3715-4296-9975-def5c7750f65",
"country": "ARG",
"amount": 100,
"currency": "ARS",
"accountNumber": "{{accountNumber}}",
"conceptCode": "0001",
"comment": "Test",
"merchant": {
"type": "COMPANY",
"name": "Company",
"document": {
"type": "DNI",
"id": "12345678"
},
"userReference": "abc123",
"email": "merchant@mail.com",
"phone": {
"countryCode": "54",
"areaCode": "11",
"number": "98781234"
}
},
"payer": {
"type": "INDIVIDUAL",
"name": "John",
"lastname": "Doe",
"document": {
"id": "37993812",
"type": "DNI"
},
"email": "john.doe@example.com",
"phone": {
"countryCode": "1",
"areaCode": "11",
"number": "98789123"
}
},
"card": {
"name": "APRO",
"number": "4000000000000002",
"cvv": "123",
"expirationMonth": "11",
"expirationYear": "2029",
"installments": 1
},
"type": "SOFTWARE",
"autoRecurring": {
"type": "day"
}
}
'
{
"subscriptionId": "133640f9-ac16-49fc-aa82-08bfe52ceb5e",
"status": {
"code": "105",
"description": "INPROGRESS",
"detail": "The subscription is in progress"
},
"creationDate": "2024-05-31T15:05:47.665+00:00",
"nextPaymentDate": "2024-06-30T15:05:47.665+00:00",
"payments": [
{
"externalId": "bb7d3235-04da-4b8a-85bf-8caf89d986ea",
"internalId": "9977c453-ce00-48fd-baac-f685bce30895",
"status": {
"code": "103",
"description": "APPROVED",
"detail": "The payin was confirmed but not credited yet"
}
}
]
}
Questo endpoint ti consente di creare un nuovo abbonamento per un cliente. Creare un abbonamento significa associare un cliente a un piano di abbonamento specifico e registrarne le informazioni di pagamento.
Autorizzazioni
Intestazioni
Token di accesso Bearer per l'autenticazione. Questo token si ottiene dagli endpoint Ottenere il token di accesso o Rinnovare il token di accesso.
Corpo
application/json
Paese del documento. ISO 3166-1 alpha-3.
Opzioni disponibili:
COL, MEX, PER Opzioni disponibili:
COP, MXN, PEN, USD Codice causale del pagamento.
Opzioni disponibili:
0001, 0002, 0003, 0004, 0005, 0006, 0007, 0008, 0009, 0010, 0011, 0012, 0013, 0014, 0015, 0016, 0017, 0018, 0019, 0020, 0021, 0022, 0023, 0024, 0025, 0026, 0027, 0028, 0029, 0030, 0031, 0032, 0033, 0034, 0035, 0036, 0037, 0038, 0039, 0040 Token fornito dal servizio di cambio valuta per usare un tasso di cambio concordato in anticipo.
Array di oggetti Party. Rappresenta le altre parti della catena di pagamento, poiché l'utente finale non è un tuo cliente diretto. Tieni conto della sequenza dell'array: il tuo cliente deve essere il primo elemento, il cliente del tuo cliente il secondo e così via, finché non ci sono più intermediari.
Risposta
OK
Ultima modifica il 22 novembre 2026

