API v2

Aggiornamenti principali rispetto all'API v1

Introduzione di campi "standard"

Con la versione 2 delle API di configurazione sono stati introdotti dei campi da introdurre obbligatoriamente in ogni integrazione.

Tenant

I campi da introdurre obbligatoriamente a livello di configurazione del tenant sono:

  • id: identificativo univoco del tenant

  • name: nome del tenant

  • tax_identification_number: codice fiscale dell'ente

Campo
Tipo
Obbligatorio
Validazione

id

UUID

Identificativo univoco

name

String

Non vuoto, massimo 255 caratteri

tax_identification_number

String

Codice fiscale valido

Configurazione pagamento

I campi da introdurre obbligatoriamente a livello di configurazione del pagamento sono:

  • payment_type: tipo di pagamento, può assumere i valori pagopa o stamp, serve a distinguere tra un pagamento ordinario (es. TARI) e una marca da bollo digitale. Questa distinzione è necessaria in quanto in alcuni intermediare i metodi di creazione di un pagamento di una marca da bollo digitale differiscono da quelli di creazione di un pagamento ordinario.

  • remote_collection.id: identificativo della collezione di provenienza della configurazione di pagamento.

  • remote_collection.type: tipo di collezione di provenienza della configurazione di pagamento, può assumere valori quali application, service o altro.

  • amount: importo del pagamento configurato.

  • reason: causale del pagamento configurato

  • expire_at: numero di giorni di validità del pagamento

  • receiver.tax_identification_number: codice fiscale del beneficiario del pagamento, da usare in caso di pagamenti multibeneficiario

  • receiver.name: nome del beneficiario del pagamento, da usare in caso di pagamenti multibeneficiario

  • collection_data: tassonomia di pagoPA dei pagamenti

Campo
Tipo
Obbligatorio
Validazione

payment_type

Enum

Valori: PAGOPA, STAMP

remote_collection.id

UUID

Identificativo univoco

remote_collection.type

String

Valori: application, service, altro

amount

float

Maggiore di 0

reason

String

Non vuoto, massimo 255 caratteri

expire_at

int

Maggiore di 0

receiver.tax_identification_number

String

Codice fiscale valido

receiver.name

String

Non vuoto, massimo 255 caratteri

collection_data

String

Tassonomia pagoPA valida

Configurazione tenant

L'admin, dall'interfaccia di configurazione dei pagamenti della Stanza del Cittadino compila la configurazione mediante una form, il cui json schema è servito dall'API /tenants/schema

Lo schema della form sopra riportata è il seguente

{
    "display": "form",
    "components": [
        {
            "label": "UUID del Tenant",
            "placeholder": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
            "spellcheck": false,
            "attributes": {
                "readonly": "readonly"
            },
            "hidden": true,
            "tableView": false,
            "validate": {
                "required": true
            },
            "key": "id",
            "type": "textfield",
            "input": true
        },
        {
            "label": "Nome dell'ente",
            "placeholder": "Comune di Bugliano",
            "tableView": true,
            "validate": {
                "required": true
            },
            "key": "name",
            "type": "textfield",
            "input": true
        },
        {
            "label": "Codice IPA dell'ente",
            "placeholder": "A000",
            "description": "Codice (tutto maiuscolo) assegnato all'Ente nel registro <a href='http://www.indicepa.gov.it' target='__blank'>indice PA</a>",
            "spellcheck": false,
            "tableView": true,
            "validate": {
                "required": true
            },
            "key": "IPA_code",
            "type": "textfield",
            "input": true
        },
        {
            "label": "Codice fiscale dell'ente",
            "placeholder": "123456789",
            "spellcheck": false,
            "key": "tax_identification_number",
            "type": "textfield",
            "validate": {
                "required": true
            },
            "input": true,
            "tableView": true
        },
        {
            "label": "Password",
            "placeholder": "************",
            "description": "Password assegnata da MyPay all\u2019Ente",
            "spellcheck": false,
            "tableView": false,
            "validate": {
                "required": true
            },
            "key": "password",
            "type": "textfield",
            "input": true
        },
        {
            "label": "Password carrello dovuti",
            "placeholder": "************",
            "description": "Password assegnata all\u2019ente creditore. Tale password va richiesta all\u2019amministratore dell\u2019ente creditore.<br>ATTENZIONE: questo dato NON coincide con la password (principale) dell\u2019ente.",
            "spellcheck": false,
            "tableView": true,
            "key": "cart_password",
            "type": "textfield",
            "input": true
        },
        {
            "label": "Codice applicazione",
            "spellcheck": false,
            "tableView": true,
            "key": "application_code",
            "type": "textfield",
            "input": true,
            "hidden": true,
            "defaultValue": "SDC"
        },
        {
            "label": "Abilitato",
            "key": "active",
            "type": "checkbox",
            "input": true,
            "hidden": true,
            "defaultValue": true
        },
        {
            "label": "Salva",
            "showValidations": false,
            "tableView": false,
            "key": "submit",
            "type": "button",
            "input": true
        }
    ]
}

Premendo poi il bottone Salva, viene eseguita una POST /tenants servita dal proxy, con payload

{
    "name": "Comune di Bugliano",
    "IPA_code": "p_tn",
    "tax_identification_number": "00337460224",
    "password": "4CKSILO7FQPZ",
    "cart_password": "",
    "application_code": "",
    "active": true,
    "enable_checkout": false,
    "id": "60e35f02-1509-408c-b101-3b1a28109329"
}

Per modificare una configurazione esistente, il proxy serve l'API PUT /tenants/{tenant_id} e PATCH /tenants/{tenant_id}

Per eliminare una configurazione esistente, il proxy serve l'API DELETE /tenants/{tenant_id} . In questo caso l'eliminazione è una soft-delete, ovvero la configurazione viene semplicemente disattivata settando il parametro active a false ed eliminando la configurazione dalla memoria ma non dallo storage.

Configurazione pagamento

L'admin, dall'interfaccia di configurazione dei pagamenti per un servizio compila la configurazione mediante una form, il cui json schema è servito dall'API /configs/schema

Lo schema della form soprariportata è il seguente

{
    "display": "form",
    "components": [
        {
            "label": "UUID del Tenant",
            "placeholder": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
            "spellcheck": false,
            "attributes": {
                "readonly": "readonly"
            },
            "hidden": true,
            "tableView": false,
            "validate": {
                "required": true
            },
            "key": "tenant_id",
            "type": "textfield",
            "input": true
        },
        {
            "label": "Container",
            "tableView": false,
            "validateWhenHidden": false,
            "key": "remote_collection",
            "type": "container",
            "input": true,
            "components": [
                {
                    "label": "UUID del Servizio",
                    "placeholder": "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX",
                    "applyMaskOn": "change",
                    "hidden": true,
                    "spellcheck": false,
                    "tableView": true,
                    "validate": {
                        "required": true
                    },
                    "validateWhenHidden": false,
                    "key": "id",
                    "attributes": {
                        "readonly": "readonly"
                    },
                    "type": "textfield",
                    "input": true
                },
                {
                    "label": "Tipo Collezione",
                    "applyMaskOn": "change",
                    "hidden": true,
                    "tableView": true,
                    "validateWhenHidden": false,
                    "key": "type",
                    "type": "textfield",
                    "input": true
                }
            ]
        },
        {
            "label": "Lista Versamenti",
            "reorder": false,
            "addAnother": "Aggiungi Versamento",
            "addAnotherPosition": "bottom",
            "layoutFixed": false,
            "enableRowGroups": false,
            "initEmpty": false,
            "tableView": false,
            "defaultValue": [
                {
                    "payment_type": "pagopa",
                    "management_id": "",
                    "reason": "",
                    "expire_at": "",
                    "receiver_enable": false,
                    "split": [],
                    "hidden": "",
                    "collection_data": "",
                    "receiver": {
                        "tax_identification_number": "",
                        "name": "",
                        "iban": ""
                    },
                    "pagopa_category": ""
                }
            ],
            "validate": {
                "minLength": "1",
                "maxLength": "1",
                "custom": "valid = true;\n\nif (input && Array.isArray(input)) {\n  for (let i = 0; i < input.length; i++) {\n    const row = input[i] || {};\n\n    const splitRows = row.split || [];\n    if (Array.isArray(splitRows) && splitRows.length > 0) {\n      const totalSplit = splitRows.reduce((sum, s) => sum + (Number(s.amount) || 0), 0);\n      const expectedAmount = Number(row.amount);\n\n      if (!isNaN(expectedAmount)) {\n        if (totalSplit !== expectedAmount) {\n          valid = `Errore nel versamento ${i + 1}: somma split (${totalSplit}) diversa da amount (${expectedAmount}).`;\n          break;\n        }\n      }\n    }\n  }\n}\n"
            },
            "validateWhenHidden": false,
            "key": "items",
            "type": "datagrid",
            "input": true,
            "components": [
                {
                    "label": "Versamenti",
                    "tableView": false,
                    "key": "versamenti",
                    "type": "fieldset",
                    "input": true,
                    "components": [
                        {
                            "label": "Scegli il tipo di pagamento",
                            "widget": "choicesjs",
                            "tableView": true,
                            "data": {
                                "values": [
                                    {
                                        "label": "PagoPA",
                                        "value": "pagopa"
                                    },
                                    {
                                        "label": "Marca da Bollo Digitale",
                                        "value": "stamp"
                                    }
                                ]
                            },
                            "validate": {
                                "required": true
                            },
                            "key": "payment_type",
                            "type": "select",
                            "input": true,
                            "defaultValue": "pagopa"
                        },
                        {
                            "label": "Tipo dovuto",
                            "placeholder": "TD_CIE",
                            "description": "Riferimento alla tipologia del dovuto secondo la classificazione data dal beneficiario. Nel caso di una marca da bollo digitale indicare MARCA_BOLLO_DIGITALE",
                            "applyMaskOn": "change",
                            "spellcheck": false,
                            "tableView": true,
                            "validate": {
                                "required": true,
                                "maxLength": 64
                            },
                            "key": "management_id",
                            "type": "textfield",
                            "input": true
                        },
                        {
                            "label": "Importo",
                            "placeholder": "12.34",
                            "description": "Le cifre decimali vanno separate dalla parte intera tramite il punto.",
                            "applyMaskOn": "change",
                            "mask": false,
                            "tableView": false,
                            "delimiter": false,
                            "requireDecimal": false,
                            "inputFormat": "plain",
                            "truncateMultipleSpaces": false,
                            "validate": {
                                "required": true,
                                "custom": "valid = (row.payment_type == 'stamp' && row.amount == 16) || (row.payment_type == 'pagopa') ? true : \"In caso di marca da bollo digitale l'unico importo permesso è di 16 euro\""
                            },
                            "validateWhenHidden": false,
                            "key": "amount",
                            "type": "number",
                            "input": true
                        },
                        {
                            "label": "Causale",
                            "applyMaskOn": "change",
                            "tableView": true,
                            "validate": {
                                "required": true,
                                "maxLength": 60
                            },
                            "key": "reason",
                            "type": "textfield",
                            "input": true
                        },
                        {
                            "label": "Validità del pagamento (in gg)",
                            "applyMaskOn": "change",
                            "mask": false,
                            "tableView": false,
                            "delimiter": false,
                            "requireDecimal": false,
                            "inputFormat": "plain",
                            "truncateMultipleSpaces": false,
                            "validate": {
                                "required": true,
                                "min": 1
                            },
                            "validateWhenHidden": false,
                            "key": "expire_at",
                            "type": "number",
                            "input": true
                        },
                        {
                            "label": "Dati specifici riscossione",
                            "placeholder": "9/3300.1",
                            "description": "Rappresenta l'indicazione dell'imputazione della specifica entrata ed è così articolato:<br><b>TIPO_CONTABILITA / CODICE_CONTABILITA</b>, dove TIPO_CONTABILITA ha il seguente significato:<ul><li>0 (Capitolo e articolo di Entrata del Bilancio dello Stato)</li><li>1 (Numero della contabilità speciale)</li><li>2 (Codice SIOPE)</li><li>9 (Altro codice ad uso dell'amministrazione)</li></ul>",
                            "applyMaskOn": "change",
                            "spellcheck": false,
                            "tableView": false,
                            "defaultValue": "9/3300.1",
                            "validate": {
                                "required": true,
                                "maxLength": 140
                            },
                            "key": "collection_data",
                            "type": "textfield",
                            "input": true
                        },
                        {
                            "label": "Categoria",
                            "widget": "choicesjs",
                            "description": "Selezione dalla Tassonomia di PagoPA dei pagamenti.",
                            "tableView": true,
                            "dataSrc": "url",
                            "data": {
                                "url": "https://api.opencityitalia.it/datasets/pagopa",
                                "headers": [
                                    {
                                        "key": "",
                                        "value": ""
                                    }
                                ]
                            },
                            "dataType": "object",
                            "idPath": "",
                            "valueProperty": "DATI SPECIFICI DI INCASSO",
                            "template": "<span>{{ item[\"NOME MACRO AREA\"] }}: {{ item[\"TIPO SERVIZIO\"] }}</span>",
                            "validate": {
                                "required": true
                            },
                            "key": "pagopa_category",
                            "type": "select",
                            "disableLimit": false,
                            "noRefreshOnScroll": false,
                            "input": true
                        },
                        {
                            "label": "Bilancio",
                            "reorder": false,
                            "addAnother": "Aggiungi bilancio",
                            "addAnotherPosition": "bottom",
                            "layoutFixed": false,
                            "enableRowGroups": false,
                            "initEmpty": true,
                            "tableView": false,
                            "calculateValue": "if (!row.split || row.split == 'undefined') {\n  row.split = []\n} else if (typeof row.split==='object' && Object.keys(row.split).length === 0) {\n  row.split = [];\n}",
                            "validateWhenHidden": false,
                            "key": "split",
                            "type": "datagrid",
                            "input": true,
                            "components": [
                                {
                                    "label": "ID",
                                    "description": "Identificativo univoco della voce di bilancio. Testo libero",
                                    "placeholder": "c_1",
                                    "tableView": true,
                                    "validate": {
                                        "required": true
                                    },
                                    "key": "id",
                                    "type": "textfield",
                                    "input": true
                                },
                                {
                                    "label": "Capitolo",
                                    "placeholder": "Capitolo di bilancio c1",
                                    "validate": {
                                        "required": true
                                    },
                                    "tableView": true,
                                    "key": "budget_chapter",
                                    "type": "textfield",
                                    "input": true
                                },
                                {
                                    "label": "Ufficio",
                                    "placeholder": "Codice ufficio bilancio c1",
                                    "tableView": true,
                                    "key": "office_code",
                                    "type": "textfield",
                                    "input": true
                                },
                                {
                                    "label": "Accertamento",
                                    "placeholder": "Accertamento c1",
                                    "tableView": true,
                                    "key": "assessment",
                                    "type": "textfield",
                                    "input": true
                                },
                                {
                                    "label": "Importo",
                                    "placeholder": "16.00",
                                    "description": "Importo della voce di bilancio. NB: La somma degli importi delle voci DEVE equivalere all'importo totale",
                                    "applyMaskOn": "change",
                                    "mask": false,
                                    "tableView": false,
                                    "delimiter": false,
                                    "requireDecimal": false,
                                    "inputFormat": "plain",
                                    "truncateMultipleSpaces": false,
                                    "validate": {
                                        "required": true
                                    },
                                    "validateWhenHidden": false,
                                    "key": "amount",
                                    "type": "number",
                                    "input": true
                                }
                            ]
                        }
                    ]
                }
            ]
        },
        {
            "label": "Abilitato",
            "key": "active",
            "type": "checkbox",
            "input": true,
            "hidden": true,
            "defaultValue": true,
            "tableView": false
        },
        {
            "type": "button",
            "label": "Salva",
            "key": "submit",
            "disableOnInvalid": true,
            "input": true,
            "tableView": false
        }
    ]
}

Premendo poi il bottone Salva, viene eseguita una POST /configs servita dal proxy, con payload

{
    "tenant_id": "60e35f02-1509-408c-b101-3b1a28109329",
    "remote_collection": {
        "id": "37dbc4a5-be4c-4246-bfad-15b9f5f5e7f3",
        "type": "service"
    },
    "items": [
        {
            "payment_type": "pagopa",
            "management_id": "SH_OPENCONTENT",
            "amount": 3.0,
            "reason": "Pagamento immediato MyPay 4 Lombardia",
            "expire_at": 180,
            "collection_data": "9/123",
            "pagopa_category": "9/123",
            "split": [],
            "receiver": {
                "tax_identification_number": "80034840167",
                "name": "Comune di Bugliano",
                "iban": "",
                "address": null,
                "building_number": null,
                "postal_code": null,
                "town_name": null,
                "country_subdivision": null,
                "country": null
            }
        }
    ],
    "active": true,
    "id": "37dbc4a5-be4c-4246-bfad-15b9f5f5e7f3"
}

Per ottenere una lista di configurazioni di pagamento (fino a un massimo di 5), il proxy serve l'API GET /configs?config_id=config_id1&config_id=config_id2

Per modificare una configurazione esistente, il proxy serve l'API PUT /configs/{config_id} e PATCH /configs/{config_id}

Per eliminare una configurazione esistente, il proxy serve l'API DELETE /configs/{config_id} . In questo caso l'eliminazione è una soft-delete, ovvero la configurazione viene semplicemente disattivata settando il parametro active a false.

Swagger di esempio

Get Tenant Form Schema

get
Responses
200
Successful Response
application/json
Responseany
get
GET /payment-proxy/iris/v2/tenants/schema HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
200

Successful Response

No content

Options Tenant Schema

options
Responses
200
Successful Response
application/json
Responseany
options
OPTIONS /payment-proxy/iris/v2/tenants/schema HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
200

Successful Response

No content

Get Tenant Configuration

get
Path parameters
tenant_idstring · uuidRequiredExample: b212c4b4-db26-4404-8c7c-47dab99dd2e6
Responses
200
Successful Response
application/json
get
GET /payment-proxy/iris/v2/tenants/{tenant_id} HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
{
  "tax_identification_number": "01234567891",
  "name": "Comune di Bugliano",
  "code": "CBugliano",
  "e2e_code": "CBugliano",
  "receiver_code": "RTIRIS",
  "e2e_receiver_code": "RTIRIS",
  "receiver_sil_id": "SIL_IRIS_ITR",
  "sil_id": "SIL_CBUGLIANO_OPEN",
  "password": "PASSWORD",
  "cert": "-----BEGIN CERTIFICATE REQUEST-----MIIB9TCCAWACAQAwgbgxGTAXBgNVBAoMEFF1b1ZhZGlzIExpbWl0ZWQxHDAaBgNVBAsME0RvY3VtZW50IERlcGFydG1lbnQxOTA3BgNVBAMMMFdoeSBhcmUgeW91IGRl-----END CERTIFICATE REQUEST-----",
  "application_code": "",
  "active": true,
  "id": "b212c4b4-db26-4404-8c7c-47dab99dd2e6"
}

Update Tenant Configuration

put
Path parameters
tenant_idstring · uuidRequiredExample: b212c4b4-db26-4404-8c7c-47dab99dd2e6
Body
tax_identification_numberstringRequired
namestringOptional
codestringRequired
e2e_codestringOptional
sil_idstringRequired
receiver_codestringOptional
e2e_receiver_codestringOptional
receiver_sil_idstringOptional
passwordstringRequired
certstringRequired
application_codestringOptionalDefault: ""
activebooleanRequired
stamp_codestringOptional
stamp_passwordstringOptional
Responses
200
Successful Response
application/json
Responseany
put
PUT /payment-proxy/iris/v2/tenants/{tenant_id} HTTP/1.1
Host: api.stanzadelcittadino.it
Content-Type: application/json
Accept: */*
Content-Length: 559

{
  "tax_identification_number": "01234567891",
  "name": "Comune di Bugliano",
  "code": "CBugliano",
  "e2e_code": "CBugliano",
  "receiver_code": "RTIRIS",
  "e2e_receiver_code": "RTIRIS",
  "receiver_sil_id": "SIL_IRIS_ITR",
  "password": "PASSWORD",
  "stamp_code": "CBugliano_SIL_E_BOLLO",
  "stamp_password": "PASSWORD",
  "sil_id": "SIL_CBUGLIANO_OPEN",
  "cert": "-----BEGIN CERTIFICATE REQUEST-----MIIB9TCCAWACAQAwgbgxGTAXBgNVBAoMEFF1b1ZhZGlzIExpbWl0ZWQxHDAaBgNVBAsME0RvY3VtZW50IERlcGFydG1lbnQxOTA3BgNVBAMMMFdoeSBhcmUgeW91IGRl-----END CERTIFICATE REQUEST-----",
  "application_code": "",
  "active": true
}

No content

Delete Tenant

delete
Path parameters
tenant_idstring · uuidRequiredExample: b212c4b4-db26-4404-8c7c-47dab99dd2e6
Responses
204
Successful Response
delete
DELETE /payment-proxy/iris/v2/tenants/{tenant_id} HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*

No content

Update Existing Tenant Configuration

patch
Path parameters
tenant_idstring · uuidRequiredExample: b212c4b4-db26-4404-8c7c-47dab99dd2e6
Body
object · NewConfigurationOptional
Responses
200
Successful Response
application/json
Responseany
patch
PATCH /payment-proxy/iris/v2/tenants/{tenant_id} HTTP/1.1
Host: api.stanzadelcittadino.it
Content-Type: application/json
Accept: */*
Content-Length: 42

{
  "tax_identification_number": "1234567891"
}

No content

Options Tenant Id

options
Responses
200
Successful Response
application/json
Responseany
options
OPTIONS /payment-proxy/iris/v2/tenants/{tenant_id} HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
200

Successful Response

No content

Save Tenant Configuration

post
Body
tax_identification_numberstringRequired
namestringOptional
codestringRequired
e2e_codestringOptional
sil_idstringRequired
receiver_codestringOptional
e2e_receiver_codestringOptional
receiver_sil_idstringOptional
passwordstringRequired
certstringRequired
application_codestringOptionalDefault: ""
activebooleanRequired
stamp_codestringOptional
stamp_passwordstringOptional
idstring · uuidRequired
Responses
201
Successful Response
application/json
Responseany
post
POST /payment-proxy/iris/v2/tenants HTTP/1.1
Host: api.stanzadelcittadino.it
Content-Type: application/json
Accept: */*
Content-Length: 538

{
  "tax_identification_number": "01234567891",
  "name": "Comune di Bugliano",
  "code": "CBugliano",
  "e2e_code": "CBugliano",
  "receiver_code": "RTIRIS",
  "e2e_receiver_code": "RTIRIS",
  "receiver_sil_id": "SIL_IRIS_ITR",
  "sil_id": "SIL_CBUGLIANO_OPEN",
  "password": "PASSWORD",
  "cert": "-----BEGIN CERTIFICATE REQUEST-----MIIB9TCCAWACAQAwgbgxGTAXBgNVBAoMEFF1b1ZhZGlzIExpbWl0ZWQxHDAaBgNVBAsME0RvY3VtZW50IERlcGFydG1lbnQxOTA3BgNVBAMMMFdoeSBhcmUgeW91IGRl-----END CERTIFICATE REQUEST-----",
  "application_code": "",
  "active": true,
  "id": "b212c4b4-db26-4404-8c7c-47dab99dd2e6"
}

No content

Options Tenants

options
Responses
200
Successful Response
application/json
Responseany
options
OPTIONS /payment-proxy/iris/v2/tenants HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
200

Successful Response

No content

Get Config Form Schema

get
Responses
200
Successful Response
application/json
Responseany
get
GET /payment-proxy/iris/v2/configs/schema HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
200

Successful Response

No content

Options Config Schema

options
Responses
200
Successful Response
application/json
Responseany
options
OPTIONS /payment-proxy/iris/v2/configs/schema HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
200

Successful Response

No content

Get Payment Configurations List

get
Query parameters
config_idsstring · uuid[]Optional

Lista id delle configurazioni di pagamento

Responses
200
Successful Response
application/json
get
GET /payment-proxy/iris/v2/configs HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
[
  {
    "tenant_id": "b212c4b4-db26-4404-8c7c-47dab99dd2e6",
    "payment_type": "pagopa",
    "code": "CONTR_PRTPM",
    "description": "Abbonamento aree di sosta",
    "active": true,
    "split": [
      {
        "split_id": "c_1",
        "split_type": "Tipo c1",
        "split_code": "Codice c1",
        "split_description": "Descrizione c1",
        "split_amount": 0.5,
        "split_budget_chapter": "Capitolo di bilancio c1",
        "split_assessment": "Accertamento c1"
      }
    ],
    "amount": 1,
    "reason": "test",
    "expire_at": 180,
    "collection_data": "9/0101100IM/",
    "office_code": "FSE",
    "office_description": "Fondo Sociale Europeo",
    "reference_code": "BOLLO_TIROCINI",
    "notes": "",
    "remote_collection": {
      "id": "23d57b65-5eb9-4f0a-a507-fbcf3057b248",
      "type": "service"
    }
  }
]

Save Payment Configuration

post
Body
tenant_idstring · uuidRequired
payment_typestringOptionalDefault: pagopa
codestringOptional
descriptionstringOptional
amountnumberRequired
reasonstring · max: 140Optional
expire_atintegerRequired
collection_datastringRequired
activebooleanRequired
office_codestringOptional
office_descriptionstringOptional
reference_codestringOptional
notesstringOptional
idstring · uuidOptional
Responses
201
Successful Response
application/json
Responseany
post
POST /payment-proxy/iris/v2/configs HTTP/1.1
Host: api.stanzadelcittadino.it
Content-Type: application/json
Accept: */*
Content-Length: 770

{
  "id": "3e68161e-9abb-43ac-99e6-39b0ece65b40",
  "tenant_id": "b212c4b4-db26-4404-8c7c-47dab99dd2e6",
  "payment_type": "pagopa",
  "code": "CONTR_PRTPM",
  "description": "Abbonamento aree di sosta",
  "active": true,
  "split": [
    {
      "split_id": "c_1",
      "split_type": "Tipo c1",
      "split_code": "Codice c1",
      "split_description": "Descrizione c1",
      "split_amount": 0.5,
      "split_budget_chapter": "Capitolo di bilancio c1",
      "split_assessment": "Accertamento c1"
    }
  ],
  "amount": 1,
  "reason": "test",
  "expire_at": 10,
  "collection_data": "9/0101100IM/",
  "office_code": "FSE",
  "office_description": "Fondo Sociale Europeo",
  "reference_code": "BOLLO_TIROCINI",
  "notes": "",
  "remote_collection": {
    "id": "3e68161e-9abb-43ac-99e6-39b0ece65b40",
    "type": "service"
  },
  "receiver": {
    "tax_identification_number": "06363391001",
    "name": "Agenzia delle Entrate"
  }
}

No content

Options Configs

options
Responses
200
Successful Response
application/json
Responseany
options
OPTIONS /payment-proxy/iris/v2/configs HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
200

Successful Response

No content

Get Payment Configuration

get
Path parameters
config_idstring · uuidRequiredExample: 23d57b65-5eb9-4f0a-a507-fbcf3057b248
Responses
200
Successful Response
application/json
get
GET /payment-proxy/iris/v2/configs/{config_id} HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
{
  "tenant_id": "b212c4b4-db26-4404-8c7c-47dab99dd2e6",
  "payment_type": "pagopa",
  "code": "CONTR_PRTPM",
  "description": "Abbonamento aree di sosta",
  "active": true,
  "split": [
    {
      "split_id": "c_1",
      "split_type": "Tipo c1",
      "split_code": "Codice c1",
      "split_description": "Descrizione c1",
      "split_amount": 0.5,
      "split_budget_chapter": "Capitolo di bilancio c1",
      "split_assessment": "Accertamento c1"
    }
  ],
  "amount": 1,
  "reason": "test",
  "expire_at": 180,
  "collection_data": "9/0101100IM/",
  "office_code": "FSE",
  "office_description": "Fondo Sociale Europeo",
  "reference_code": "BOLLO_TIROCINI",
  "notes": "",
  "remote_collection": {
    "id": "23d57b65-5eb9-4f0a-a507-fbcf3057b248",
    "type": "service"
  }
}

Update Payment Configuration

put
Path parameters
config_idstring · uuidRequiredExample: 23d57b65-5eb9-4f0a-a507-fbcf3057b248
Body
tenant_idstring · uuidRequired
payment_typestringOptionalDefault: pagopa
codestringOptional
descriptionstringOptional
amountnumberRequired
reasonstring · max: 140Optional
expire_atintegerRequired
collection_datastringRequired
activebooleanRequired
office_codestringOptional
office_descriptionstringOptional
reference_codestringOptional
notesstringOptional
Responses
200
Successful Response
application/json
Responseany
put
PUT /payment-proxy/iris/v2/configs/{config_id} HTTP/1.1
Host: api.stanzadelcittadino.it
Content-Type: application/json
Accept: */*
Content-Length: 727

{
  "tenant_id": "b212c4b4-db26-4404-8c7c-47dab99dd2e6",
  "payment_type": "pagopa",
  "code": "CONTR_PRTPM",
  "description": "Abbonamento aree di sosta",
  "active": true,
  "split": [
    {
      "split_id": "c_1",
      "split_type": "Tipo c1",
      "split_code": "Codice c1",
      "split_description": "Descrizione c1",
      "split_amount": 0.5,
      "split_budget_chapter": "Capitolo di bilancio c1",
      "split_assessment": "Accertamento c1"
    }
  ],
  "amount": 1,
  "reason": "test",
  "expire_at": 180,
  "collection_data": "9/0101100IM/",
  "office_code": "FSE",
  "office_description": "Fondo Sociale Europeo",
  "reference_code": "BOLLO_TIROCINI",
  "notes": "",
  "remote_collection": {
    "id": "3e68161e-9abb-43ac-99e6-39b0ece65b40",
    "type": "service"
  },
  "receiver": {
    "tax_identification_number": "06363391001",
    "name": "Agenzia delle Entrate"
  }
}

No content

Delete Config

delete
Path parameters
config_idstring · uuidRequiredExample: 23d57b65-5eb9-4f0a-a507-fbcf3057b248
Responses
204
Successful Response
delete
DELETE /payment-proxy/iris/v2/configs/{config_id} HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*

No content

Update Existing Payment Configuration

patch
Path parameters
config_idstring · uuidRequiredExample: 23d57b65-5eb9-4f0a-a507-fbcf3057b248
Body
object · NewConfigurationOptional
Responses
200
Successful Response
application/json
Responseany
patch
PATCH /payment-proxy/iris/v2/configs/{config_id} HTTP/1.1
Host: api.stanzadelcittadino.it
Content-Type: application/json
Accept: */*
Content-Length: 589

{
  "payment_type": "pagopa",
  "code": "CONTR_PRTPM",
  "description": "Abbonamento aree di sosta",
  "active": true,
  "split": [
    {
      "split_id": "c_1",
      "split_type": "Tipo c1",
      "split_code": "Codice c1",
      "split_description": "Descrizione c1",
      "split_amount": 0.5,
      "split_budget_chapter": "Capitolo di bilancio c1",
      "split_assessment": "Accertamento c1"
    }
  ],
  "amount": 1,
  "reason": "test",
  "expire_at": 10,
  "collection_data": "9/0101100IM/",
  "office_code": "FSE",
  "office_description": "Fondo Sociale Europeo",
  "reference_code": "BOLLO_TIROCINI",
  "notes": "",
  "remote_collection": {
    "id": "3e68161e-9abb-43ac-99e6-39b0ece65b40",
    "type": "service"
  }
}

No content

Options Config Id

options
Responses
200
Successful Response
application/json
Responseany
options
OPTIONS /payment-proxy/iris/v2/configs/{config_id} HTTP/1.1
Host: api.stanzadelcittadino.it
Accept: */*
200

Successful Response

No content

Last updated

Was this helpful?