Skip to content
Last updated

Lean - getDisposableContractWitheIDAssertion method

This method works with the eIDAssertion and returns:

  • the disposable contract (Mod_NAMCA22D)
  • the privacy document url
  • the T&C document url

Check How to enroll a disposable with an assertion provided by an authorized eID for more details.

The disposable contract (Mod_NAMCA22D)

For the full technical reference, see the OpenAPI specification.

Endpoint

POST /api/document/{lraId}/getDisposableContractWithEidAssertion

Headers

NameRequiredDescription
Content-TypeYesMust be application/json.
AuthorizationYesBasic Auth credentials.

Path parameters

ParameterTypeRequiredDescription
lraIdintegerYesLRA identifier.

Body parameters

ParameterTypeRequiredDescription
languageCodearrayYesLanguage(s) of the document. ISO 639-1 alpha-2 codes.
docTypesarrayYesDocument type(s). 1 = PDF, 2 = TXT.
certobjectYesDisposableCertificate object.
countrystringNoCountry where the end user is located. ISO 3166-1 alpha-2. If omitted, the default template for the specified languageCode is returned.
eIDAssertionHolderobjectNoDisposableeIDAssertionHolder object.
disposableContactsobjectNoDisposableContacts object.

Request example

{
    "eIDAssertionHolder": {
        "assertion": "encoded base64 assertion",
        "country": "IT",
        "eIDType": "SPID"
    },
    "cert": {
        "type": "DISPOSABLE_30_DAYS",
        "withoutUsageLimitLRA": true
    },
    "contacts": {
        "email": "user@example.com",
        "mobile": "+390000000000"
    },
    "languageCode": ["IT"],
    "docTypes": [1]
}

Response examples

200 — Contract returned

[
    {
        "languageCode": "IT",
        "docTypes": 2,
        "doc": "encoded file",
        "privacy_link": "https://docs.namirialtsp.com/documents/Mod_NAM_GDPR03D_ITA_IT.pdf",
        "termsAndConditions_link": "https://docs.namirialtsp.com/documents/Mod_NAM_CA01D_ITA_IT.pdf",
        "checkBoxes": [
            "Al fine di perfezionare la sottoscrizione del Modulo di richiesta con firma elettronica, è necessario accettare i termini e le condizioni della fornitura richiesta contrassegnando con segno di spunta le caselle sottostanti:",
            "(1) Io sottoscritto/a dichiaro quanto indicato nel QUADRO E - AUTOCERTIFICAZIONE E SOTTOSCRIZIONE DA PARTE DEL TITOLARE.",
            "(2) Io sottoscritto/a accetto le Condizioni Generali di Contratto (Mod.NAM CA01) e le clausole vessatorie riportate nel QUADRO F – CLAUSOLE VESSATORIE"
        ]
    }
]

Error codes

The main errors that can be found within this method are (all return HTTP 500):

Error codeDescription
2Some required fields are missing
235Wrong assertion
237The assertion is expired
238The assertion signature is invalid
241LRA not authorized to use this OTP type
2083Contract template not found
2084The specified language was not found
10094Product does not exist

For authentication errors, see Authentication.

For details on how to handle errors, see How to handle errors.