Skip to Content
Certificates

Certificates

Digital certificates

HTTP header parameters

  • Authorization (string): API authorisation. Example: Bearer {token}

Base URL

https://api.saltra.es/api/v4/certificate

Get certificates

Parameters

  • clientId optional (integer): Client identifier (id). Only for querying the client’s certificates.
GET /
{ "clientId": 1 }

Response

Respuesta
{ "success": true, "message": "OK", "data": { "data": [ { "name": "99999999", "desde": "2023-12-12", "expired": "2026-12-12", "dni": "ISSS-999999Q", "gn": "NAME", "sn": "NAME", "type": 1, "active": 1, "cert_secret": "283261f59c9c4fqh123f8defe269999999e3c17b21" } ], "pagination": { "page": 1, "lastPage": 1, "perPage": 50, "total": 2 } } }

Save a certificate

Parameters

  • file (file): Certificate in P12 or PFX format.
  • password (string): Certificate password.
  • clientId optional (integer): Client identifier (id). Only for saving the client’s certificates.
  • type (integer): Certificate type. Possible values:
    • 1: RED Authorised User (TGSS)
    • 2: SEPE
    • 3: Tax Agency (AEAT)
    • 5: DEHU
POST /
curl -X POST https://api.saltra.es/api/v4/certificate \ -H 'Authorization: bearer *token*' \ -H 'Accept: application/json' \ -F 'password="1234"' \ -F 'type="1"' \ -F 'clientId="1"' \ -F 'file=@"certificado.p12"'

Response

Respuesta
{ "success": true, "message": "OK", "data": { "name": "99999999", "desde": "2023-12-12", "expired": "2026-12-12", "dni": "ISSS-999999Q", "gn": "NAME", "sn": "NAME", "type": 1, "active": 1, "cert_secret": "283261f59c9c4fqh123f8defe269999999e3c17b21" } }

Delete a certificate

Parameters

  • cert_secret (string): Secret key associated with the certificate.
DELETE /{cert_secret}
cert_secret

Response

Respuesta
{ "success": true, "message": "OK" }
Last updated on