{"openapi":"3.0.1","info":{"description":"Web services for the activation and management of Certified Email (PEC). These services allow you to register a new certified mailbox, as well as renew or revoke existing accounts. You can also modify mailbox options such as total storage and archive space, or enable and expand legally compliant preservation. Furthermore, the system includes methods to report a certified email address to the Business Register. Finally, you can use these services to download and upload activation forms for both the mailbox and the legal preservation service.","version":"1.0.0","title":"Pec (Posta Elettronica Certificata)","termsOfService":"https://openapi.it/en/terms-and-conditions","contact":{"url":"https://openapi.it/en/support","name":"Support"},"license":{"name":"Apache 2.0","url":"http://www.apache.org/licenses/LICENSE-2.0.html"}},"servers":[{"url":"https://pec.openapi.it","description":"Production"},{"url":"https://test.pec.openapi.it","description":"Sandbox"}],"tags":[{"name":"Pec","description":"Methods that allow you to register, activate and modify a certified e-mail"},{"name":"Comunica Pec","description":"Methods that allow you to communicate a certified e-mail to the business register"},{"name":"Domini","description":"Methods that allow you to activate and modify a certified domain"},{"name":"Modulistica","description":"Methods that allow you to download the forms necessary for the management of certified e-mail boxes"}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}},"schemas":{"BodyPostPec":{"type":"object","properties":{"casella_pec":{"type":"string","description":"the certified email address (PEC)"},"tipo_casella":{"type":"string","description":"type of mailbox","enum":["STANDARD","BRONZE","SILVER","GOLD","DOMICILIODIGITALE","PECMASSIVA"]},"tipo_cliente":{"type":"string","description":"the customer type","enum":["IM","PS","PL","PC","A","PV","X"]},"sottotipo_cliente":{"type":"string","description":"the customer subtype","enum":["SI","IN","CM","TE","ES","ME","AL","CF","ED","TM","MA","AR","TL","FI","X","PC","PR","PN","PT","PA","PL","LR","LP","LC","LM","LA","LI"]},"sottotipo_cliente_altro":{"type":"string","description":"other customer subtype"},"nome_richiedente":{"type":"string","description":"first name of the applicant"},"cognome_richiedente":{"type":"string","description":"last name of the applicant"},"email":{"type":"string","description":"standard email address of the applicant"},"telefono":{"type":"string","description":"phone number of the applicant"},"cellulare":{"type":"string","description":"mobile phone number of the applicant"},"codice_fiscale_richiedente":{"type":"string","description":"fiscal code of the applicant"},"data_nascita_richiedente":{"type":"string","description":"date of birth of the applicant"},"sesso_richiedente":{"type":"string","description":"gender of the applicant","enum":["M","F"]},"nazione_nascita_richiedente":{"type":"string","description":"country of birth of the applicant"},"comune_nascita_richiedente":{"type":"string","description":"city of birth of the applicant"},"provincia_nascita_richiedente":{"type":"string","description":"province of birth of the applicant"},"denominazione_titolare":{"type":"string","description":"name of the mailbox holder"},"cf_piva_titolare":{"type":"string","description":"fiscal code or VAT number of the mailbox holder"},"indirizzo_titolare":{"type":"string","description":"address of the mailbox holder"},"comune_titolare":{"type":"string","description":"city of the mailbox holder"},"cap_titolare":{"type":"string","description":"postal code (CAP) of the mailbox holder"},"nazione_titolare":{"type":"string","description":"country of the mailbox holder"},"provincia_titolare":{"type":"string","description":"province of the mailbox holder"},"callback":{"$ref":"#/components/schemas/Callback"},"autorinnovo":{"type":"boolean","description":"if set to true, it allows the system to renew the account automatically upon expiration, trying to withdraw credit from the owner's purse","default":false},"tipo_documento":{"type":"string","description":"type of identification document","enum":["CARTA_D_IDENTITA","PATENTE","PASSAPORTO"]},"numero_documento":{"type":"string","description":"number of the document"},"data_scadenza_documento":{"type":"string","description":"expiration date of the document"},"documento_rilasciato_da":{"type":"string","description":"issuing authority of the document"},"data_rilascio_documento":{"type":"string","description":"Issue date of the document"}},"required":["casella_pec","tipo_casella","tipo_cliente","nome_richiedente","cognome_richiedente","email","telefono","codice_fiscale_richiedente","data_nascita_richiedente","sesso_richiedente","nazione_nascita_richiedente","indirizzo_titolare","comune_titolare","cap_titolare","nazione_titolare","provincia_titolare"]},"BodyPostDominio":{"type":"object","required":["dominio","fornitore"],"properties":{"dominio":{"type":"string","description":"The domain name to activate (e.g. example.com)","example":"testdominio.legalmail.it"},"callback":{"$ref":"#/components/schemas/Callback"},"fornitore":{"type":"string","enum":["infocert","namirial"],"description":"The service provider","example":"infocert"},"anni":{"type":"integer","description":"Number of years for which the domain is purchased","default":1,"example":1,"enum":[1,2,3,4,5,6,7,8,9,10]},"numero_pec":{"type":"integer","description":"Number of PEC boxes purchased for the domain","default":1,"example":1}}},"Dominio":{"type":"object","properties":{"id":{"type":"string","description":"Domain ID","example":"69806bcce09fb76c6b0fef0b"},"dominio":{"type":"string","description":"Domain name","example":"testdominio.legalmail.it"},"fornitore":{"type":"string","enum":["infocert","namirial"],"description":"The service provider","example":"infocert"},"owner":{"type":"string","description":"Username of the domain owner","example":"mail@domain.com"},"stato_fornitore":{"type":"string","enum":["OK","KO","PENDING"],"description":"State of the domain on the provider side","example":"OK"},"dns":{"type":"string","description":"DNS configuration state from provider","example":"OK"},"config":{"type":"string","description":"Server configuration state from provider","example":"OK"},"certif":{"type":"string","description":"Certification state from provider","example":"MISSING"},"tipo_dominio":{"type":"string","enum":["interno","esterno"],"description":"Domain type (internal or external)","example":"interno"},"stato":{"type":"string","enum":["registrato","evaso","revocato"],"description":"Internal processing status","example":"registrato"},"data_scadenza":{"type":"string","description":"Expiration date (dd/mm/yyyy)","example":"02/02/2027"},"data_certificazione":{"type":"string","description":"Certification date (dd/mm/yyyy)","example":"02/02/2026"},"timestamp":{"$ref":"#/components/schemas/Timestamp"},"id_ordine":{"type":"string","description":"Order ID associated with the activation","example":"62558f"},"autorinnovo":{"type":"boolean","default":false,"description":"If true, the domain will be automatically renewed","example":false},"anni":{"type":"integer","description":"Number of years for which the domain is purchased","example":1},"numero_pec":{"type":"integer","description":"Number of PEC boxes purchased for the domain","example":1},"callback":{"$ref":"#/components/schemas/Callback"}}},"BodyPostComunicaPec":{"type":"object","properties":{"casella_pec":{"type":"string","description":"the certified email address (PEC)"},"cf":{"type":"string","description":"fiscal code"},"nome":{"type":"string","description":"first name"},"cognome":{"type":"string","description":"last name"},"qualifica":{"type":"string","description":"qualification of the owner","enum":["AMMINISTRATORE","COMMISSARIO_GIUDIZIARIO","CURATORE_FALLIMENTARE","LEGALE_RAPPRESENTANTE","LIQUIDATORE","SOCIO","TITOLARE"]},"email":{"type":"string","description":"email of the owner"},"cellulare":{"type":"string","description":"mobile phone of the owner"},"ragione_sociale":{"type":"string","description":"company name"},"cf_piva":{"type":"string","description":"company's fiscal code or VAT number"},"comune":{"type":"string","description":"municipality of the company"},"provincia":{"type":"string","description":"province of the company"},"callback":{"$ref":"#/components/schemas/Callback"}},"required":["casella_pec","cf","nome","cognome","qualifica","email","cellulare","ragione_sociale","cf_piva","comune","provincia"]},"BodyPostMultiutenza":{"type":"object","properties":{"nome":{"type":"string","description":"first name"},"cognome":{"type":"string","description":"last name"},"descrizione":{"type":"string","description":"description"},"email_gestione_password":{"type":"string","description":"email of the user"}},"required":["nome","cognome","descrizione","email_gestione_password"]},"TipologieCliente":{"type":"object","properties":{"IM":{"type":"string","description":"Impresa","enum":["SI - SERVIZI IMPRESE","IN - INFORMATICA","CM - COMMERCIO","TE - TELECOMUNICAZIONI","ES - EDITORIA STAMPA","ME - MECCANICA ELETTRICA","AL - ALIMENTARE","CF - CHIMICA FARMACEUTICA","ED - EDILIZIA","TM - TESSILE MODA","MA - MOBILI ARREDAMENTI","AR - ALBERGHI RISTORANTI","TL - TRASPOSRTI LOGISTICA","FI - FINANZA","X - ALTRO"]},"PS":{"type":"string","description":"Professionista","enum":["PC - COMMERCIALISTA","PR - RAGIONIERE","PN - NOTAIO","PT - TRIBUTARISTA","PA - AVVOCATO","PL - CONSULENTE LAVORO","X - ALTRO"]},"PL":{"type":"string","description":"Pubblica Amministrazione Locale","enum":["LR - REGIONE","LP - PROVINCIA","LC - COMUNE","LM - COMUNITA MONTANA","LA - ASL","LI - CCIAA","X - ALTRO"]},"PC":{"type":"string","description":"Pubblica Amministrazione Centrale"},"A":{"type":"string","description":"Associazione"},"PV":{"type":"string","description":"Privato"},"X":{"type":"string","description":"Altro"}}},"Casella":{"type":"object","properties":{"casella_pec":{"type":"string","description":"the certified email address (PEC)"},"tipo_casella":{"type":"string","description":"type of mailbox","enum":["STANDARD","BRONZE","SILVER","GOLD","DOMICILIODIGITALE","PECMASSIVA"]},"tipo_cliente":{"type":"string","description":"the customer type"},"sottotipo_cliente":{"type":"string","description":"the customer subtype"},"sottotipo_cliente_altro":{"type":"string","description":"other customer subtype"},"nome_richiedente":{"type":"string","description":"first name of the applicant"},"cognome_richiedente":{"type":"string","description":"last name of the applicant"},"email":{"type":"string","description":"standard email address of the applicant"},"telefono":{"type":"string","description":"phone number of the applicant"},"cellulare":{"type":"string","description":"mobile phone number of the applicant"},"codice_fiscale_richiedente":{"type":"string","description":"fiscal code of the applicant"},"data_nascita_richiedente":{"type":"string","description":"date of birth of the applicant"},"sesso_richiedente":{"type":"string","description":"gender of the applicant"},"nazione_nascita_richiedente":{"type":"string","description":"country of birth of the applicant"},"comune_nascita_richiedente":{"type":"string","description":"city of birth of the applicant"},"provincia_nascita_richiedente":{"type":"string","description":"province of birth of the applicant"},"denominazione_titolare":{"type":"string","description":"name of the mailbox holder"},"cf_piva_titolare":{"type":"string","description":"fiscal code or VAT number of the mailbox holder"},"indirizzo_titolare":{"type":"string","description":"address of the mailbox holder"},"comune_titolare":{"type":"string","description":"city of the mailbox holder"},"cap_titolare":{"type":"string","description":"postal code (CAP) of the mailbox holder"},"nazione_titolare":{"type":"string","description":"country of the mailbox holder"},"provincia_titolare":{"type":"string","description":"province of the mailbox holder"},"callback":{"$ref":"#/components/schemas/Callback"},"dominio":{"type":"string","description":"the domain name associated with the PEC mailbox"},"owner":{"type":"string","description":"identifier for the owner"},"timestamp":{"$ref":"#/components/schemas/Timestamp"},"cod_attivazione":{"type":"string","description":"activation code for the mailbox"},"uid":{"type":"string","description":"unique identifier for the mailbox or request"},"conservazione":{"type":"boolean","description":"indicates if legal electronic retention (conservazione a norma) is active"},"data_scadenza":{"type":"string","description":"expiration date of the service/mailbox"},"descrizione":{"type":"string","description":"description"},"sms":{"type":"boolean","description":"indicates if SMS notifications are active]"},"spazio_conservazione":{"type":"integer","description":"allocated storage space for legal retention in MB"},"spazio_disco":{"type":"integer","description":"total disk space allocated for the mailbox in MB)"},"spazio_storico":{"type":"integer","description":"allocated storage space for historical data/archive in MB"},"stato":{"type":"string","enum":["registrata","in_attivazione","evasa","revocata","chiusa"],"description":"current status of the mailbox/request"},"storico":{"type":"boolean","description":"indicates if historical data access or archiving feature is active"},"documenti_attivazione":{"type":"array","items":{"type":"string"},"description":"array of strings  for activation documents"},"data_attivazione":{"type":"string","description":"activation date of the mailbox"},"documenti_conservazione":{"type":"array","items":{"type":"string"},"description":"array of strings for retention documents"},"multiutenza":{"type":"array","items":{"$ref":"#/components/schemas/Utenza"}},"id":{"type":"string","description":"object ID"},"autorinnovo":{"type":"boolean","description":"if set to true, it allows the system to renew the account automatically upon expiration, trying to withdraw credit from the owner's purse"},"tipo_documento":{"type":"string","enum":["CARTA_D_IDENTITA","PATENTE","PASSAPORTO"],"description":"type of identification document"},"numero_documento":{"type":"string","description":"number of the document"},"data_scadenza_documento":{"type":"string","description":"expiration date of the document"},"documento_rilasciato_da":{"type":"string","description":"issuing authority of the document"},"data_rilascio_documento":{"type":"string","description":"Issue date of the document"}}},"Callback":{"type":"object","properties":{"method":{"type":"string","description":"Indicate through which method you want to receive data with the callback, by default it is POST","enum":["POST","JSON"]},"field":{"type":"string","description":"Name of the field containing the callback return data"},"url":{"type":"string","description":"Url where the callback call will be made","example":"https://www.mysite.it/callback.php"},"data":{"type":"object","description":"Object to be completed at your convenience with additional data that you can use back with the callback"}}},"Timestamp":{"type":"object","properties":{"registrazione":{"type":"integer","description":"registration/creation time"},"ultima_modifica":{"type":"integer","description":"last modification time"},"evasione":{"type":"integer","description":"completion/resolution time"},"certificazione":{"type":"integer","description":"certification/activation time"},"scadenza":{"type":"integer","description":"expiration/deadline time"},"revoca":{"type":"integer","description":"revocation time"}}},"RichiesteComunicazionePec":{"type":"object","properties":{"id":{"type":"string","description":"object ID"},"casella_pec":{"type":"string","description":"the certified email address (PEC)"},"stato":{"type":"string","description":"Request status","enum":["codice_in_richiesta","in_attesa_di_documenti","documenti_caricati","comunicazione_evasa"]},"timestamp":{"type":"integer"},"owner":{"type":"string","description":"identifier for the owner"}}},"RichiestaComunicazionePec":{"type":"object","properties":{"casella_pec":{"type":"string","description":"the certified email address (PEC)"},"cf":{"type":"string","description":"fiscal code"},"nome":{"type":"string","description":"first name"},"cognome":{"type":"string","description":"last name"},"qualifica":{"type":"string","description":"qualification of the applicant","enum":["AMMINISTRATORE","COMMISSARIO_GIUDIZIARIO","CURATORE_FALLIMENTARE","LEGALE_RAPPRESENTANTE","LIQUIDATORE","SOCIO","TITOLARE"]},"email":{"type":"string","description":"email of the owner"},"cellulare":{"type":"string","description":"mobile phone of the owner"},"ragione_sociale":{"type":"string","description":"compain name"},"cf_piva":{"type":"string","description":"company's fiscal code or VAT number"},"comune":{"type":"string","description":"municipality of the company"},"provincia":{"type":"string","description":"province of the company"},"callback":{"$ref":"#/components/schemas/Callback"},"stato":{"type":"string","enum":["codice_in_richiesta","in_attesa_di_documenti","documenti_caricati","comunicazione_evasa"]},"codice_registro_imprese":{"type":"string"},"documenti_registro_imprese":{"type":"array","items":{"type":"string"}},"owner":{"type":"string","description":"identifier for the owner"},"timestamp":{"type":"integer"},"id":{"type":"string","description":"object ID"}}},"Utenza":{"type":"object","properties":{"nome":{"type":"string","description":"first name"},"cognome":{"type":"string","description":"last name"},"descrizione":{"type":"string","description":"notes"},"email_gestione_password":{"type":"string","description":"email address used for password management"},"id_utenza":{"type":"string","description":"identifier for the user account"},"timestamp":{"type":"object","properties":{"attivazione":{"type":"integer","description":"activation timestamp for the account"}}},"userid":{"type":"string","description":"user login identifier"}}},"Caselle":{"type":"object","properties":{"casella_pec":{"type":"string","description":"the certified email address (PEC)"},"tipo_casella":{"type":"string","description":"type of mailbox","enum":["STANDARD","BRONZE","SILVER","GOLD","DOMICILIODIGITALE","PECMASSIVA"]},"owner":{"type":"string","description":"identifier for the owner"},"timestamp":{"$ref":"#/components/schemas/Timestamp"},"data_scadenza":{"type":"string","description":"expiration Date"},"stato":{"type":"string","description":"processing status","enum":["registrata","in_attivazione","evasa","revocata","chiusa"]},"id":{"type":"string","description":"object ID"}}}}},"paths":{"/dominio":{"get":{"tags":["Domini"],"summary":"List all domains associated with the account","operationId":"getDominiList","responses":{"200":{"description":"List of domains","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Dominio"}}}}}}},"404":{"description":"No domains found","content":{"application/json":{"example":{"success":false,"message":"no domains linked to this account","error":701,"data":null}}}}}},"post":{"tags":["Domini"],"summary":"Activate a new certified domain","operationId":"postDominio","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BodyPostDominio"}}}},"responses":{"200":{"description":"Domain activation started","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Dominio"}}},"example":{"data":{"dominio":"testdominio.legalmail.it","fornitore":"infocert","owner":"gcloud-tests@openapi.it","stato_fornitore":"KO","dns":"OK","config":"KO","certif":"KO","tipo_dominio":"interno","stato":"registrato","data_scadenza":"02/02/2027","timestamp":{"registrazione":1770023882,"scadenza":1801559882,"ultima_modifica":1770023884},"anni":1,"numero_pec":1,"id_ordine":"62558f","autorinnovo":false,"callback":{"url":"https://www.mysite.it/callback.php","method":"POST","field":"string"},"id":"69806bcce09fb76c6b0fef0b"}}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"examples":{"already_present":{"value":{"success":false,"message":"domain already present in the system","error":712,"data":null}},"invalid_domain":{"value":{"success":false,"message":"domain not valid","error":711,"data":null}},"unreachable":{"value":{"success":false,"message":"The domain '...' is unreachable","error":715,"data":null}}}}}},"428":{"description":"Precondition Required","content":{"application/json":{"examples":{"domain_required":{"value":{"success":false,"message":"domain required","error":703,"data":null}},"no_mx":{"value":{"success":false,"message":"Invalid domain: no MX record found...","error":714,"data":null}}}}}}}}},"/dominio/{id}":{"get":{"tags":["Domini"],"summary":"Get details of a specific domain","operationId":"getDominio","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","example":"69806bcce09fb76c6b0fef0b"},"description":"The domain ID"}],"responses":{"200":{"description":"Domain details","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Dominio"}}},"example":{"data":{"dominio":"testdominio.legalmail.it","fornitore":"infocert","owner":"gcloud-tests@openapi.it","stato_fornitore":"OK","dns":"OK","config":"OK","certif":"OK","tipo_dominio":"interno","stato":"evaso","data_scadenza":"02/02/2027","timestamp":{"registrazione":1770023882,"scadenza":1801559882,"ultima_modifica":1770023884,"certificazione":1770023884},"anni":1,"numero_pec":1,"id_ordine":"62558f","autorinnovo":false,"callback":{"url":"https://www.mysite.it/callback.php","method":"POST","field":"data"},"data_certificazione":"03/03/2026","id":"69806bcce09fb76c6b0fef0b"}}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no domain found","error":702,"data":null}}}}}},"delete":{"tags":["Domini"],"summary":"Revoke a certified domain","operationId":"deleteDominio","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","example":"69806bcce09fb76c6b0fef0b"},"description":"The domain ID to revoke"}],"responses":{"200":{"description":"Domain revoked","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"message":{"type":"string"},"data":{"$ref":"#/components/schemas/Dominio"}}},"example":{"success":true,"message":"Domain and associated boxes revoked","data":{"dominio":"pec.testgestionale.com","fornitore":"infocert","owner":"gcloud-tests@openapi.it","stato_fornitore":"OK","dns":"OK","config":"OK","certif":"OK","tipo_dominio":"esterno","stato":"revocato","data_scadenza":"13/03/2054","data_certificazione":"13/03/2026","timestamp":{"registrazione":1773401265,"scadenza":2657014065,"ultima_modifica":1774273311,"certificazione":1773401405,"revoca":1774273558},"autorinnovo":false,"anni":1,"numero_pec":3,"id_ordine":"1a54cf","callback":{"url":"https://www.mysite.it/callback.php"},"id":"69b3f4b1d0747173230c4448"}}}}},"428":{"description":"Precondition Required","content":{"application/json":{"examples":{"id_required":{"value":{"success":false,"message":"id required","error":705,"data":null}},"already_revoked":{"value":{"success":false,"message":"your domain has already been revoked","error":716,"data":null}}}}}}}}},"/dominio/{id}/rinnovo":{"get":{"tags":["Domini"],"summary":"Renew a certified domain","operationId":"renewDominio","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","example":"69806bcce09fb76c6b0fef0b"},"description":"The domain ID"},{"name":"anni","in":"query","schema":{"type":"integer","default":1,"enum":[1,2,3,4,5,6,7,8,9,10]},"description":"Number of years for renewal. Default 1."}],"responses":{"200":{"description":"Renewal result","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Dominio"}}},"example":{"data":{"dominio":"pec.testgestionale.com","fornitore":"infocert","owner":"gcloud-tests@openapi.it","stato_fornitore":"OK","dns":"OK","config":"OK","certif":"OK","tipo_dominio":"esterno","stato":"evaso","data_scadenza":"13/03/2054","data_certificazione":"13/03/2026","timestamp":{"registrazione":1773401265,"scadenza":2657014065,"ultima_modifica":1774273311,"certificazione":1773401405},"autorinnovo":false,"anni":1,"numero_pec":3,"id_ordine":"1a54cf","callback":{"url":"https://www.mysite.it/callback.php"},"id":"69b3f4b1d0747173230c4448"}}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no domain found","error":702,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"examples":{"cannot_renew":{"value":{"success":false,"message":"cannot renew domain with status: ...","error":716,"data":null}},"invalid_years":{"value":{"success":false,"message":"years must be between 1 and 10","error":717,"data":null}}}}}}}}},"/domini_pec/{dominio}":{"get":{"tags":["Pec"],"summary":"Domain check","description":"This method allows you to check if a domain is eligible for sending or receiving a pec","parameters":[{"name":"dominio","in":"path","description":"Domain","required":true,"schema":{"type":"string","example":"legalmail.it"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"string"}},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":[],"success":true,"message":"legalmail.it found!","error":null}}}},"204":{"description":"No Content"},"402":{"description":"Payment Required","content":{"application/json":{"example":{"success":false,"message":"Insufficient Credit in Wallet: 182.03","error":403,"data":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"domain not valid","error":709,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"domain required","error":700,"data":null}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"example":{"success":false,"message":"service temporarily unavailable","error":710,"data":null}}}}}}},"/verifica_pec/{pec}":{"get":{"tags":["Pec"],"summary":"Availability of a certified e-mail box","description":"This method shows you the availability of a certified e-mail box. It can only verify the availability of mailboxes for domains configured and managed by the system. For unmanaged domains, it will return an error since their existence cannot be verified.","parameters":[{"name":"pec","in":"path","description":"Email box","required":true,"schema":{"type":"string","example":"prova_pec@legalmail.it"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"available":{"type":"boolean","description":"Shows if the email address can be registered"}}},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"available":true},"success":true,"message":"","error":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"invalid casella_pec","error":208,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"examples":{"casella_pec_required":{"value":{"success":false,"message":"casella_pec required","error":212,"data":null}},"unmanaged_domain":{"value":{"success":false,"message":"we cannot know if the mailbox exists for unmanaged domains","error":253,"data":null}}}}}}}}},"/pec":{"get":{"tags":["Pec"],"summary":"List of your certified e-mail boxes","description":"This method shows you the list of certified e-mail boxes that belong to your account","parameters":[{"name":"skip","in":"query","description":"Optional. Number of items to skip for pagination. If not specified, the default value is 0.","required":false,"schema":{"type":"integer","example":0}},{"name":"limit","in":"query","description":"Optional. Maximum number of items to return. If not specified, the default value is 100.","required":false,"schema":{"type":"integer","example":100}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Caselle"}},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":[{"id":"6040e4613a716838dc4eee0e","casella_pec":"mypec@testcert.legalmail.it","tipo_casella":"BRONZE","stato":"revocata","data_scadenza":"04/03/2022","timestamp":{"registrazione":1614865504,"ultima_modifica":1614868403,"evasione":1614868312,"scadenza":1646391493,"revoca":1614868400},"owner":"mail@domain.com"},{"id":"6040c9df3a716838dc4eede4","casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"STANDARD","stato":"evasa","data_scadenza":"04/03/2022","timestamp":{"registrazione":1614858718,"ultima_modifica":1614859181,"evasione":1614859181,"scadenza":1646391493},"owner":"mail@domain.com"}],"success":true,"message":"","error":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec linked to this account","error":200,"data":null}}}}}},"post":{"tags":["Pec"],"summary":"Register a new certified mailbox","description":"This method allows you to register a new certified mailbox. \n\nIf you do not have your own certified domain, the mailbox must necessarily consist of: \n\n- 'box_name'@legalmail.it (Es. provapec@legalmail.it) for STANDARD, BRONZE, SILVER AND GOLD mailbox; \n\n- 'box_name'@domiciliodigitale.com (Es. provapec@domiciliodigitale.com) for DOMICILIODIGITALE box; \n\n- 'box_name'@pecmassiva.com (Es. provapec@pecmassiva.com) for PECMASSIVA box. \n\nIn Sandbox must be: 'box_name'@testcert.legalmail.it (Es. provapec@testcert.legalmail.it) or 'box_name'@test.domiciliodigitale.com (Es. provapec@test.domiciliodigitale.com).","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BodyPostPec"},"example":{"casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"bronze","tipo_cliente":"PV","sottotipo_cliente":"","sottotipo_cliente_altro":"","nome_richiedente":"mario","cognome_richiedente":"rossi","email":"mail@domain.com","telefono":"0548798569","codice_fiscale_richiedente":"RSSXXXXXXXX56E","data_nascita_richiedente":"11/04/1982","sesso_richiedente":"M","nazione_nascita_richiedente":"it","provincia_nascita_richiedente":"RM","denominazione_titolare":"","cf_piva_titolare":"","indirizzo_titolare":"via verdi 20","comune_titolare":"roma","cap_titolare":"00042","nazione_titolare":"it","provincia_titolare":"rm","callback":{"url":"https://your_domain.it/your_callback.php","field":"data"}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Casella"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"BRONZE","tipo_cliente":"PV","sottotipo_cliente":"","sottotipo_cliente_altro":"","nome_richiedente":"mario","cognome_richiedente":"rossi","email":"mail@domain.com","telefono":"0548798569","codice_fiscale_richiedente":"RSSXXXXXXXX56E","data_nascita_richiedente":"11/04/1982","sesso_richiedente":"M","nazione_nascita_richiedente":"IT","provincia_nascita_richiedente":"RM","denominazione_titolare":"","cf_piva_titolare":"","indirizzo_titolare":"via verdi 20","comune_titolare":"roma","cap_titolare":"00042","nazione_titolare":"IT","provincia_titolare":"rm","callback":{"url":"https://your_domain.it/your_callback.php","field":"data","method":"POST","data":{}},"dominio":"testcert.legalmail.it","owner":"mail@domain.com","timestamp":{"registrazione":1615199724,"ultima_modifica":1615199726},"cellulare":"","comune_nascita_richiedente":"","cod_attivazione":"10174594","uid":"MA178634","conservazione":false,"data_scadenza":"","descrizione":"prova.sviluppo@testcert.legalmail.it","sms":false,"spazio_conservazione":0,"spazio_disco":0,"spazio_storico":0,"stato":"registrata","storico":false,"id":"6045fdee3a716847a978a471","autorinnovo":false},"success":true,"message":"","error":null}}}},"402":{"description":"Payment Required","content":{"application/json":{"example":{"success":false,"message":"Insufficient Credit in Wallet: 182.03","error":262,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"the domain $dominio is non-existent in the system or belongs to someone else","error":326,"data":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"data_nascita_richiedente not valid, accepted format: dd/mm/yyyy","error":242,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"tipo_casella required","error":224,"data":null}}}}}}},"/pec/{id}":{"get":{"tags":["Pec"],"summary":"Specific certified e-mail address","description":"This method shows you the specific certified e-mail address related to the id","parameters":[{"name":"id","in":"path","description":"Pec id","required":true,"schema":{"type":"string","example":"6040e4613a716838dc4eee0e"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Casella"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"BRONZE","tipo_cliente":"PV","sottotipo_cliente":"","sottotipo_cliente_altro":"","nome_richiedente":"mario","cognome_richiedente":"rossi","email":"mail@domain.com","telefono":"0548798569","codice_fiscale_richiedente":"RSSXXXXXXXX56E","data_nascita_richiedente":"11/04/1982","sesso_richiedente":"M","nazione_nascita_richiedente":"IT","provincia_nascita_richiedente":"RM","denominazione_titolare":"","cf_piva_titolare":"","indirizzo_titolare":"via verdi 20","comune_titolare":"roma","cap_titolare":"00042","nazione_titolare":"IT","provincia_titolare":"rm","callback":{"url":"https://your_domain.it/your_callback.php","field":"data","method":"POST","data":{}},"dominio":"testcert.legalmail.it","owner":"mail@domain.com","timestamp":{"registrazione":1614865504,"ultima_modifica":1614868403,"evasione":1614868312,"scadenza":1646391493,"revoca":1614868400},"cellulare":"","comune_nascita_richiedente":"","cod_attivazione":"10173956","uid":"MA177987","conservazione":true,"data_scadenza":"04/03/2022","descrizione":"yourpec@testcert.legalmail.it","sms":true,"spazio_conservazione":512,"spazio_disco":3072,"spazio_storico":3072,"stato":"revocata","storico":true,"documenti_attivazione":["6040e4613a716838dc4eee0e_0_attivazione.pdf","6040e4613a716838dc4eee0e_1_attivazione.pdf"],"data_attivazione":"04/03/2021","documenti_conservazione":["6040e4613a716838dc4eee0e_0_conservazione.pdf","6040e4613a716838dc4eee0e_1_conservazione.pdf"],"multiutenza":[{"nome":"luca","cognome":"bianchi","descrizione":"prima utenza","email_gestione_password":"mail@domain.com","id_utenza":"6040e4613a716838dc4eee0e_0","timestamp":{"attivazione":1614868138},"userid":"MA177993"}],"id":"6040e4613a716838dc4eee0e","autorinnovo":false},"success":true,"message":"","error":null}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":201,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":202,"data":null}}}}}},"delete":{"tags":["Pec"],"summary":"Pec revocation","description":"This method allows you to revoke the specific certified e-mail address related to the id","parameters":[{"name":"id","in":"path","description":"Pec id","required":true,"schema":{"type":"string","example":"6040e4613a716838dc4eee0e"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Casella"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"BRONZE","tipo_cliente":"PV","sottotipo_cliente":"","sottotipo_cliente_altro":"","nome_richiedente":"mario","cognome_richiedente":"rossi","email":"mail@domain.com","telefono":"0548798569","codice_fiscale_richiedente":"RSSXXXXXXXX56E","data_nascita_richiedente":"11/04/1982","sesso_richiedente":"M","nazione_nascita_richiedente":"IT","provincia_nascita_richiedente":"RM","denominazione_titolare":"","cf_piva_titolare":"","indirizzo_titolare":"via verdi 20","comune_titolare":"roma","cap_titolare":"00042","nazione_titolare":"IT","provincia_titolare":"rm","callback":{"url":"https://your_domain.it/your_callback.php","field":"data","method":"POST","data":{}},"dominio":"testcert.legalmail.it","owner":"mail@domain.com","timestamp":{"registrazione":1614865504,"ultima_modifica":1614868403,"evasione":1614868312,"scadenza":1646391493,"revoca":1614868400},"cellulare":"","comune_nascita_richiedente":"","cod_attivazione":"10173956","uid":"MA177987","conservazione":true,"data_scadenza":"04/03/2022","descrizione":"yourpec@testcert.legalmail.it","sms":true,"spazio_conservazione":512,"spazio_disco":3072,"spazio_storico":3072,"stato":"revocata","storico":true,"documenti_attivazione":["6040e4613a716838dc4eee0e_0_attivazione.pdf","6040e4613a716838dc4eee0e_1_attivazione.pdf"],"data_attivazione":"04/03/2021","documenti_conservazione":["6040e4613a716838dc4eee0e_0_conservazione.pdf","6040e4613a716838dc4eee0e_1_conservazione.pdf"],"multiutenza":[{"nome":"luca","cognome":"bianchi","descrizione":"prima utenza","email_gestione_password":"mail@domain.com","id_utenza":"6040e4613a716838dc4eee0e_0","timestamp":{"attivazione":1614868138},"userid":"MA177993"}],"id":"6040e4613a716838dc4eee0e","autorinnovo":false},"success":true,"message":"","error":null}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":301,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":302,"data":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"your pec has already been revoked","error":303,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"you can revoke the pec only if it is active","error":304,"data":null}}}}}}},"/pec/{id}/attivazione":{"patch":{"tags":["Pec"],"summary":"Certified e-mail activation","description":"This method allows you, once you have registered your certified electronic mailbox, to activate it by uploading the necessary documentation. The required documentation includes your valid identity document and the completed and signed activation form that you can download using the method GET/pec/{id}/modulo_attivazione. For the boxes of type DOMICILIODIGITALE and PECMASSIVA it is necessary to create a single document comprising the signed activation form and the identity document.","parameters":[{"name":"id","in":"path","description":"Pec id","required":true,"schema":{"type":"string","example":"6045fdee3a716847a978a471"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"documenti":{"oneOf":[{"type":"string","description":"base64_encode(file content); only pdf files are allowed"},{"type":"array","items":{"type":"string","description":"base64_encode(file content); only pdf files are allowed"}}]}}},"example":{"documenti":["JVBERi0xLjUKJeLjz9MKNyAwIG9iago8PAovVHlwZSAvRm9udERlc2NyaXB0b3IKL0ZvbnROYW1lIC9UaW1lcyMyME5ldyMyMFJvbWFuCi9GbGFncyAzMgovSXRhbGljQW5nbGUgMAovQXNjZW50IDg5MQovRGVzY2VudCAtMjE2Ci9DYXBIZWlnaHQgNjkzCi9BdmdXaWR0aCA0MDEKL01heFdpZHRoIDI2MTQKL0ZvbnRXZWlnaHQgNDAwCi9YSGVpZ2h0IDI1MAovTGVhZGluZyA0MgovU3RlbVYgNDAKL0ZvbnRCQm94IFstNTY4IC0yMTYgMjA0NiA2OTNdCj4+CmVuZG9iago4IDAgb2JqClsyNTAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAyNTAgMCA1MDAgMCA1MDAgMCAwIDUwMCA1MDAgNTAwIDUwMCA1MDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgNDQ0IDAgNDQ0IDAgMCAwIDAgMCAyNzggMCAwIDAgMCA1MDAgNTAwIDUwMCAwIDMzMyAzODkgMjc4IDAgNTAwXQplbmRvYmoKNiAwIG9iago8PAovVHlwZSAvRm9udAovU3VidHlwZSAvVHJ1ZVR5cGUKL05hbWUgL0YxCi9CYXNlRm9udCAvVGltZXMjMjBOZXcjMjBSb21hbgovRW5jb2RpbmcgL1dpbkFuc2lFbmNvZGluZwovRm9udERlc2NyaXB0b3IgNyAwIFIKL0ZpcnN0Q2hhciAzMgovTGFzdENoYXIgMTE4Ci9XaWR0aHMgOCAwIFIKPj4KZW5kb2JqCjkgMCBvYmoKPDwKL1R5cGUgL0V4dEdTdGF0ZQovQk0gL05vcm1hbAovY2EgMQo+PgplbmRvYmoKMTAgMCBvYmoKPDwKL1R5cGUgL0V4dEdTdGF0ZQovQk0gL05vcm1hbAovQ0EgMQo+PgplbmRvYmoKMTEgMCBvYmoKPDwKL0ZpbHRlciAvRmxhdGVEZWNvZ","JVBERi0xLjUKJeLjz9MKNyAwIG9iago8PAovVHlwZSAvRm9udERlc2NyaXB0b3IKL0ZvbnROYW1lIC9UaW1lcyMyME5ldyMyMFJvbWFuCi9GbGFncyAzMgovSXRhbGljQW5nbGUgMAovQXNjZW50IDg5MQovRGVzY2VudCAtMjE2Ci9DYXBIZWlnaHQgNjkzCi9BdmdXaWR0aCA0MDEKL01heFdpZHRoIDI2MTQKL0ZvbnRXZWlnaHQgNDAwCi9YSGVpZ2h0IDI1MAovTGVhZGluZyA0MgovU3RlbVYgNDAKL0ZvbnRCQm94IFstNTY4IC0yMTYgMjA0NiA2OTNdCj4+CmVuZG9iago4IDAgb2JqClsyNTAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAyNTAgMCA1MDAgMCA1MDAgMCAwIDUwMCA1MDAgNTAwIDUwMCA1MDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAw"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Casella"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"BRONZE","tipo_cliente":"PV","sottotipo_cliente":"","sottotipo_cliente_altro":"","nome_richiedente":"mario","cognome_richiedente":"rossi","email":"mail@domain.com","telefono":"0548798569","codice_fiscale_richiedente":"RSSXXXXXXXX56E","data_nascita_richiedente":"11/04/1982","sesso_richiedente":"M","nazione_nascita_richiedente":"IT","provincia_nascita_richiedente":"RM","denominazione_titolare":"","cf_piva_titolare":"","indirizzo_titolare":"via verdi 20","comune_titolare":"roma","cap_titolare":"00042","nazione_titolare":"IT","provincia_titolare":"rm","callback":{"url":"https://your_domain.it/your_callback.php","field":"data","method":"POST","data":{}},"dominio":"testcert.legalmail.it","owner":"mail@domain.com","timestamp":{"registrazione":1615199724,"ultima_modifica":1615200175},"cellulare":"","comune_nascita_richiedente":"","cod_attivazione":"10174594","uid":"MA178634","conservazione":false,"data_scadenza":"","descrizione":"yourpec@testcert.legalmail.it","sms":false,"spazio_conservazione":0,"spazio_disco":0,"spazio_storico":0,"stato":"in_evasione","storico":false,"documenti_attivazione":["6045fdee3a716847a978a471_0_attivazione.pdf","6045fdee3a716847a978a471_1_attivazione.pdf"],"id":"6045fdee3a716847a978a471","autorinnovo":false},"success":true,"message":"","error":null}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":265,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":266,"data":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"wrong file format, pdf required","error":296,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"you can activate the pec only when it is in the 'registrata' state","error":267,"data":null}}}}}}},"/pec/{id}/modifica":{"patch":{"tags":["Pec"],"summary":"Change mailbox space","description":"This method allows you to change the space of a certified e-mail. You can change the disk space('spazio_disco'), the security archive space('spazio_storico') and the standard storage space('spazio_conservazione'). Only a space upgrade is allowed. Action not allowed for these two types of boxes: DOMICILIODIGITALE, PECMASSIVA.","parameters":[{"name":"id","in":"path","description":"Pec id","required":true,"schema":{"type":"string","example":"6045fdee3a716847a978a471"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"spazio_disco":{"oneOf":[{"type":"string","example":"+1024","multipleOf":1024},{"type":"integer","example":1024,"multipleOf":1024}],"description":"If you put the + symbol in front you go to add space to what you have. If you pass only a number go to set the space with that value."},"spazio_storico":{"oneOf":[{"type":"string","example":"+1024","multipleOf":1024},{"type":"integer","example":1024,"multipleOf":1024}],"description":"If you put the + symbol in front you go to add space to what you have. If you pass only a number go to set the space with that value."},"spazio_conservazione":{"oneOf":[{"type":"string","example":"+512","multipleOf":512},{"type":"integer","example":512,"multipleOf":512}],"description":"If you put the + symbol in front you go to add space to what you have. If you pass only a number go to set the space with that value."}}},"example":{"spazio_disco":"3072","spazio_storico":"+1024","spazio_conservazione":1536}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Casella"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"GOLD","tipo_cliente":"PV","sottotipo_cliente":"","sottotipo_cliente_altro":"","nome_richiedente":"mario","cognome_richiedente":"rossi","email":"mail@domain.com","telefono":"0548798569","codice_fiscale_richiedente":"RSSXXXXXXXX56E","data_nascita_richiedente":"11/04/1982","sesso_richiedente":"M","nazione_nascita_richiedente":"IT","provincia_nascita_richiedente":"RM","denominazione_titolare":"","cf_piva_titolare":"","indirizzo_titolare":"via verdi 20","comune_titolare":"roma","cap_titolare":"00042","nazione_titolare":"IT","provincia_titolare":"rm","callback":{"url":"https://your_domain.it/your_callback.php","field":"data","method":"POST","data":{}},"dominio":"testcert.legalmail.it","owner":"mail@domain.com","timestamp":{"registrazione":1615199724,"evasione":1615199724,"scadenza":1646391493,"ultima_modifica":1615200175},"cellulare":"","comune_nascita_richiedente":"","cod_attivazione":"10174594","uid":"MA178634","conservazione":true,"data_attivazione":"20/04/2021","data_scadenza":"20/04/2022","descrizione":"yourpec@testcert.legalmail.it","sms":true,"spazio_conservazione":1536,"spazio_disco":3072,"spazio_storico":14336,"stato":"evasa","storico":true,"documenti_attivazione":["6045fdee3a716847a978a471_0_attivazione.pdf","6045fdee3a716847a978a471_1_attivazione.pdf"],"documenti_conservazione":["6045fdee3a716847a978a471_0_conservazione.pdf"],"id":"6045fdee3a716847a978a471","autorinnovo":false},"success":true,"message":"","error":null}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":265,"data":null}}}},"402":{"description":"Payment Required","content":{"application/json":{"example":{"success":false,"message":"Insufficient Credit in Wallet: 182.03","error":290,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":266,"data":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"the system only takes into account multiples of 1024","error":325,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"you must first activate the 'conservazione' service","error":282,"data":null}}}}}}},"/pec/{id}/conservazione":{"patch":{"tags":["Pec"],"summary":"Activation of conservation according to law","description":"This method allows you to activate the standard storage service in your certified e-mail. Action not allowed for these two types of boxes: DOMICILIODIGITALE, PECMASSIVA.","parameters":[{"name":"id","in":"path","description":"Pec id","required":true,"schema":{"type":"string","example":"6045fdee3a716847a978a471"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"spazio_conservazione":{"oneOf":[{"type":"string","example":"1024","multipleOf":512},{"type":"integer","example":1024,"multipleOf":512}],"description":"If this parameter is not passed it is set to 512 by default"},"documenti":{"oneOf":[{"type":"string","description":"base64_encode(file content); only pdf files are allowed"},{"type":"array","items":{"type":"string","description":"base64_encode(file content); only pdf files are allowed"}}]}},"required":["documenti"]},"example":{"spazio_conservazione":1024,"documenti":"JVBERi0xLjUKJeLjz9MKNyAwIG9iago8PAovVHlwZSAvRm9udERlc2NyaXB0b3IKL0ZvbnROYW1lIC9UaW1lcyMyME5ldyMyMFJvbWFuCi9GbGFncyAzMgovSXRhbGljQW5nbGUgMAovQXNjZW50IDg5MQovRGVzY2VudCAtMjE2Ci9DYXBIZWlnaHQgNjkzCi9BdmdXaWR0aCA0MDEKL01heFdpZHRoIDI2MTQKL0ZvbnRXZWlnaHQgNDAwCi9YSGVpZ2h0IDI1MAovTGVhZGluZyA0MgovU3RlbVYgNDAKL0ZvbnRCQm94IFstNTY4IC0yMTYgMjA0NiA2OTNdCj4+CmVuZG9iago4IDAgb2JqClsyNTAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAyNTAgMCA1MDAgMCA1MDAgMCAwIDUwMCA1MDAgNTAwIDUwMCA1MDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgNDQ0IDAgNDQ0IDAgMCAwIDAgMCAyNzggMCAwIDAgMCA1MDAgNTAwIDUwMCAwIDMzMyAzODkgMjc4IDAgNTAwXQplbmRvYmoKNiAwIG9iago8PAovVHlwZSAvRm9udAovU3VidHlwZSAvVHJ1ZVR5cGUKL05hbWUgL0YxCi9CYXNlRm9udCAvVGltZXMjMjBOZXcjMjBSb21hbgovRW5jb2RpbmcgL1dpbkFuc2lFbmNvZGluZwovRm9udERlc2NyaXB0b3IgNyAwIFIKL0ZpcnN0Q2hhciAzMgovTGFzdENoYXIgMTE4Ci9XaWR0aHMgOCAwIFIKPj4KZW5kb2JqCjkgMCBvYmoKPDwKL1R5cGUgL0V4dEdTdGF0ZQovQk0gL05vcm1hbAovY2EgMQo+PgplbmRvYmoKMTAgMCBvYmoKPDwKL1R5cGUgL0V4dEdTdGF0ZQovQk0gL05vcm1hbAovQ0EgMQo+PgplbmRvYmoKMTEgMCBvYmoKPDwKL0ZpbHRlciAvRmxhdGVEZWNvZ"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Casella"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"GOLD","tipo_cliente":"PV","sottotipo_cliente":"","sottotipo_cliente_altro":"","nome_richiedente":"mario","cognome_richiedente":"rossi","email":"mail@domain.com","telefono":"0548798569","codice_fiscale_richiedente":"RSSXXXXXXXX56E","data_nascita_richiedente":"11/04/1982","sesso_richiedente":"M","nazione_nascita_richiedente":"IT","provincia_nascita_richiedente":"RM","denominazione_titolare":"","cf_piva_titolare":"","indirizzo_titolare":"via verdi 20","comune_titolare":"roma","cap_titolare":"00042","nazione_titolare":"IT","provincia_titolare":"rm","callback":{"url":"https://your_domain.it/your_callback.php","field":"data","method":"POST","data":{}},"dominio":"testcert.legalmail.it","owner":"mail@domain.com","timestamp":{"registrazione":1615199724,"evasione":1615199724,"scadenza":1646391493,"ultima_modifica":1615200175},"cellulare":"","comune_nascita_richiedente":"","cod_attivazione":"10174594","uid":"MA178634","conservazione":true,"data_attivazione":"20/04/2021","data_scadenza":"20/04/2022","descrizione":"yourpec@testcert.legalmail.it","sms":true,"spazio_conservazione":1024,"spazio_disco":2048,"spazio_storico":13312,"stato":"evasa","storico":true,"documenti_attivazione":["6045fdee3a716847a978a471_0_attivazione.pdf","6045fdee3a716847a978a471_1_attivazione.pdf"],"documenti_conservazione":["6045fdee3a716847a978a471_0_conservazione.pdf"],"id":"6045fdee3a716847a978a471","autorinnovo":false},"success":true,"message":"","error":null}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":265,"data":null}}}},"402":{"description":"Payment Required","content":{"application/json":{"example":{"success":false,"message":"Insufficient Credit in Wallet: 182.03","error":297,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":266,"data":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"conservazione service is already active","error":293,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"documenti required","error":294,"data":null}}}}}}},"/pec/{id}/trasformazione":{"patch":{"tags":["Pec"],"summary":"Change box type","description":"This method allows you to change the type of certified email. Only upgrades are allowed, for example from a STANDARD you can switch to a SILVER or GOLD one. Action not allowed for these two types of boxes: DOMICILIODIGITALE, PECMASSIVA.","parameters":[{"name":"id","in":"path","description":"Pec id","required":true,"schema":{"type":"string","example":"6045fdee3a716847a978a471"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"tipo_casella":{"type":"string","description":"type of mailbox","enum":["STANDARD","BRONZE","SILVER","GOLD"]}}},"example":{"tipo_casella":"GOLD"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Casella"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"GOLD","tipo_cliente":"PV","sottotipo_cliente":"","sottotipo_cliente_altro":"","nome_richiedente":"mario","cognome_richiedente":"rossi","email":"mail@domain.com","telefono":"0548798569","codice_fiscale_richiedente":"RSSXXXXXXXX56E","data_nascita_richiedente":"11/04/1982","sesso_richiedente":"M","nazione_nascita_richiedente":"IT","provincia_nascita_richiedente":"RM","denominazione_titolare":"","cf_piva_titolare":"","indirizzo_titolare":"via verdi 20","comune_titolare":"roma","cap_titolare":"00042","nazione_titolare":"IT","provincia_titolare":"rm","callback":{"url":"https://your_domain.it/your_callback.php","field":"data","method":"POST","data":{}},"dominio":"testcert.legalmail.it","owner":"mail@domain.com","timestamp":{"registrazione":1615199724,"evasione":1615199724,"scadenza":1646391493,"ultima_modifica":1615200175},"cellulare":"","comune_nascita_richiedente":"","cod_attivazione":"10174594","uid":"MA178634","conservazione":false,"data_attivazione":"20/04/2021","data_scadenza":"20/04/2022","descrizione":"yourpec@testcert.legalmail.it","sms":true,"spazio_conservazione":0,"spazio_disco":2048,"spazio_storico":13312,"stato":"evasa","storico":true,"documenti_attivazione":["6045fdee3a716847a978a471_0_attivazione.pdf","6045fdee3a716847a978a471_1_attivazione.pdf"],"id":"6045fdee3a716847a978a471","autorinnovo":false},"success":true,"message":"","error":null}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":265,"data":null}}}},"402":{"description":"Payment Required","content":{"application/json":{"example":{"success":false,"message":"Insufficient Credit in Wallet: 182.03","error":279,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":266,"data":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"a downgrade of the 'tipo_casella' is not allowed; only SILVER or GOLD allowed","error":276,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"you can trasform your certified mail only if it has been processed","error":272,"data":null}}}}}}},"/pec/{id}/rinnovo":{"get":{"tags":["Pec"],"summary":"Renewal of certified e-mail","description":"This method allows you to renew for one year or re-activate the certified e-mail identified by the id","parameters":[{"name":"id","in":"path","description":"Pec id","required":true,"schema":{"type":"string","example":"6040e4613a716838dc4eee0e"}},{"name":"anni","in":"query","description":"Number of years for which you want to renew the pec box. If not passed it is 1 by default","required":false,"schema":{"type":"integer","example":2}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Casella"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"BRONZE","tipo_cliente":"PV","sottotipo_cliente":"","sottotipo_cliente_altro":"","nome_richiedente":"mario","cognome_richiedente":"rossi","email":"mail@domain.com","telefono":"0548798569","codice_fiscale_richiedente":"RSSXXXXXXXX56E","data_nascita_richiedente":"11/04/1982","sesso_richiedente":"M","nazione_nascita_richiedente":"IT","provincia_nascita_richiedente":"RM","denominazione_titolare":"","cf_piva_titolare":"","indirizzo_titolare":"via verdi 20","comune_titolare":"roma","cap_titolare":"00042","nazione_titolare":"IT","provincia_titolare":"rm","callback":{"url":"https://your_domain.it/your_callback.php","field":"data","method":"POST","data":{}},"dominio":"testcert.legalmail.it","owner":"mail@domain.com","timestamp":{"registrazione":1614865504,"ultima_modifica":1614868403,"evasione":1614868312,"scadenza":1646391493},"cellulare":"","comune_nascita_richiedente":"","cod_attivazione":"10173956","uid":"MA177987","conservazione":true,"data_scadenza":"04/03/2022","descrizione":"yourpec@testcert.legalmail.it","sms":true,"spazio_conservazione":512,"spazio_disco":3072,"spazio_storico":3072,"stato":"evasa","storico":true,"documenti_attivazione":["6040e4613a716838dc4eee0e_0_attivazione.pdf","6040e4613a716838dc4eee0e_1_attivazione.pdf"],"data_attivazione":"04/03/2021","documenti_conservazione":["6040e4613a716838dc4eee0e_0_conservazione.pdf","6040e4613a716838dc4eee0e_1_conservazione.pdf"],"multiutenza":[{"nome":"luca","cognome":"bianchi","descrizione":"prima utenza","email_gestione_password":"mail@domain.com","id_utenza":"6040e4613a716838dc4eee0e_0","timestamp":{"attivazione":1614868138},"userid":"MA177993"}],"id":"6040e4613a716838dc4eee0e","autorinnovo":false},"success":true,"message":"","error":null}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":201,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":202,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"you can renew only evaded or revoked pec","error":203,"data":null}}}}}}},"/pec/{id}/multiutenza":{"post":{"tags":["Pec"],"summary":"Add user","description":"This method allows you to add a user who can use an existing pec box. It can only be activated on STANDARD, BRONZE, SILVER, and GOLD mailboxes.","parameters":[{"name":"id","in":"path","description":"Pec id","required":true,"schema":{"type":"string","example":"6040e4613a716838dc4eee0e"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BodyPostMultiutenza"},"example":{"nome":"luca","cognome":"bianchi","descrizione":"prima utenza","email_gestione_password":"mail@domain.com"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Casella"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"yourpec@testcert.legalmail.it","tipo_casella":"BRONZE","tipo_cliente":"PV","sottotipo_cliente":"","sottotipo_cliente_altro":"","nome_richiedente":"mario","cognome_richiedente":"rossi","email":"mail@domain.com","telefono":"0548798569","codice_fiscale_richiedente":"RSSXXXXXXXX56E","data_nascita_richiedente":"11/04/1982","sesso_richiedente":"M","nazione_nascita_richiedente":"IT","provincia_nascita_richiedente":"RM","denominazione_titolare":"","cf_piva_titolare":"","indirizzo_titolare":"via verdi 20","comune_titolare":"roma","cap_titolare":"00042","nazione_titolare":"IT","provincia_titolare":"rm","callback":{"url":"https://your_domain.it/your_callback.php","field":"data","method":"POST","data":{}},"dominio":"testcert.legalmail.it","owner":"mail@domain.com","timestamp":{"registrazione":1614865504,"ultima_modifica":1614868403,"evasione":1614868312,"scadenza":1646391493},"cellulare":"","comune_nascita_richiedente":"","cod_attivazione":"10173956","uid":"MA177987","conservazione":true,"data_scadenza":"04/03/2022","descrizione":"yourpec@testcert.legalmail.it","sms":true,"spazio_conservazione":512,"spazio_disco":3072,"spazio_storico":3072,"stato":"evasa","storico":true,"documenti_attivazione":["6040e4613a716838dc4eee0e_0_attivazione.pdf","6040e4613a716838dc4eee0e_1_attivazione.pdf"],"data_attivazione":"04/03/2021","documenti_conservazione":["6040e4613a716838dc4eee0e_0_conservazione.pdf","6040e4613a716838dc4eee0e_1_conservazione.pdf"],"multiutenza":[{"nome":"luca","cognome":"bianchi","descrizione":"prima utenza","email_gestione_password":"mail@domain.com","id_utenza":"6040e4613a716838dc4eee0e_0","timestamp":{"attivazione":1614868138},"userid":"MA177993"}],"id":"6040e4613a716838dc4eee0e","autorinnovo":false},"success":true,"message":"","error":null}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":212,"data":null}}}},"402":{"description":"Payment Required","content":{"application/json":{"example":{"success":false,"message":"Insufficient Credit in Wallet: 182.03","error":220,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":213,"data":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"maximum number of users reached: 25","error":217,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"this service cannot be activated on these boxes: DOMICILIODIGITALE|PECMASSIVA","error":390,"data":null}}}}}}},"/comunica_pec":{"get":{"tags":["Comunica Pec"],"summary":"List of your communications","description":"This method shows you all the certified e-mail communications to the business register started","parameters":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/RichiesteComunicazionePec"}},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":[{"id":"60ad149c3a7168084f1d2b68","casella_pec":"mypec@pec.com","stato":"comunicazione_evasa","timestamp":1622127248,"owner":"mail@domain.com"},{"id":"60ad0f2a3a716801f42a9773","casella_pec":"yourpec@pec.it","stato":"comunicazione_evasa","timestamp":1622126850,"owner":"mail@domain.com"}],"success":true,"message":"","error":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no request linked to this account","error":332,"data":null}}}}}},"post":{"tags":["Comunica Pec"],"summary":"Communicate a certified e-mail","description":"This method allows you to communicate a certified e-mail to the business register","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BodyPostComunicaPec"},"example":{"casella_pec":"mypec@pec.com","cf":"RSSMRA80A01L117D","nome":"mario","cognome":"rossi","qualifica":"LEGALE_RAPPRESENTANTE","email":"mail@domain.com","cellulare":"34xxxxxx18","ragione_sociale":"azienda test","cf_piva":"12345678910","comune":"roma","provincia":"RM"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/RichiestaComunicazionePec"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"mypec@pec.com","cf":"RSSMRA80A01L117D","nome":"mario","cognome":"rossi","qualifica":"LEGALE_RAPPRESENTANTE","email":"mail@domain.com","cellulare":"34xxxxxx18","ragione_sociale":"azienda test","cf_piva":"12345678910","comune":"roma","provincia":"RM","callback":false,"stato":"codice_in_richiesta","codice_registro_imprese":"openapi","documenti_registro_imprese":[],"owner":"mail@domain.com","timestamp":1621955739,"id":"60ad149c3a7168084f1d2b68"},"success":true,"message":"","error":null}}}},"402":{"description":"Payment Required","content":{"application/json":{"example":{"success":false,"message":"Insufficient Credit in Wallet: 182.03","error":351,"data":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"invalid casella_pec","error":336,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"cf_piva required","error":344,"data":null}}}}}}},"/comunica_pec/{id}":{"get":{"tags":["Comunica Pec"],"summary":"Specific request for communication pec","description":"This method returns you the specific request marked with the id","parameters":[{"name":"id","in":"path","description":"Comunica Pec id","required":true,"schema":{"type":"string","example":"60ad149c3a7168084f1d2b68"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/RichiestaComunicazionePec"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"mypec@pec.com","cf":"RSSMRA80A01L117D","nome":"mario","cognome":"rossi","qualifica":"LEGALE_RAPPRESENTANTE","email":"mail@domain.com","cellulare":"349xxxxx18","ragione_sociale":"azienda test","cf_piva":"12345678910","comune":"roma","provincia":"RM","callback":false,"stato":"comunicazione_evasa","codice_registro_imprese":"openapi","documenti_registro_imprese":["60ad149c3a7168084f1d2b68_0_registro_imprese.p7m"],"owner":"mail@domain.com","timestamp":1622127248,"id":"60ad149c3a7168084f1d2b68"},"success":true,"message":"","error":null}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":333,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no request found","error":334,"data":null}}}}}},"patch":{"tags":["Comunica Pec"],"summary":"Upload the documents","description":"This method allows you to complete the request for communication of your pec to the business register by uploading the necessary documentation. The required documentation includes the completed and digitally signed in p7m format form that you can download using the method GET/comunica_pec/{id}/procura_registro_imprese.","parameters":[{"name":"id","in":"path","description":"Comunica Pec id","required":true,"schema":{"type":"string","example":"60dc8da86c8b04624536bbb2"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"documenti":{"oneOf":[{"type":"string","description":"base64_encode(file content); only p7m files are allowed"},{"type":"array","items":{"type":"string","description":"base64_encode(file content); only p7m files are allowed"}}]}}},"example":{"documenti":"JVBERi0xLjUKJeLjz9MKNyAwIG9iago8PAovVHlwZSAvRm9udERlc2NyaXB0b3IKL0ZvbnROYW1lIC9UaW1lcyMyME5ldyMyMFJvbWFuCi9GbGFncyAzMgovSXRhbGljQW5nbGUgMAovQXNjZW50IDg5MQovRGVzY2VudCAtMjE2Ci9DYXBIZWlnaHQgNjkzCi9BdmdXaWR0aCA0MDEKL01heFdpZHRoIDI2MTQKL0ZvbnRXZWlnaHQgNDAwCi9YSGVpZ2h0IDI1MAovTGVhZGluZyA0MgovU3RlbVYgNDAKL0ZvbnRCQm94IFstNTY4IC0yMTYgMjA0NiA2OTNdCj4+CmVuZG9iago4IDAgb2JqClsyNTAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAyNTAgMCA1MDAgMCA1MDAgMCAwIDUwMCA1MDAgNTAwIDUwMCA1MDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgNDQ0IDAgNDQ0IDAgMCAwIDAgMCAyNzggMCAwIDAgMCA1MDAgNTAwIDUwMCAwIDMzMyAzODkgMjc4IDAgNTAwXQplbmRvYmoKNiAwIG9iago8PAovVHlwZSAvRm9udAovU3VidHlwZSAvVHJ1ZVR5cGUKL05hbWUgL0YxCi9CYXNlRm9udCAvVGltZXMjMjBOZXcjMjBSb21hbgovRW5jb2RpbmcgL1dpbkFuc2lFbmNvZGluZwovRm9udERlc2NyaXB0b3IgNyAwIFIKL0ZpcnN0Q2hhciAzMgovTGFzdENoYXIgMTE4Ci9XaWR0aHMgOCAwIFIKPj4KZW5kb2JqCjkgMCBvYmoKPDwKL1R5cGUgL0V4dEdTdGF0ZQovQk0gL05vcm1hbAovY2EgMQo+PgplbmRvYmoKMTAgMCBvYmoKPDwKL1R5cGUgL0V4dEdTdGF0ZQovQk0gL05vcm1hbAovQ0EgMQo+PgplbmRvYmoKMTEgMCBvYmoKPDwKL0ZpbHRlciAvRmxhdGVEZWNvZ"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/RichiestaComunicazionePec"},"success":{"type":"boolean","description":"Operation success (true/false)."},"message":{"type":"string","description":"error message"},"error":{"type":"integer","description":"error code"}}},"example":{"data":{"casella_pec":"mypec@pec.com","cf":"RSSMRA80A01L117D","nome":"mario","cognome":"rossi","qualifica":"LEGALE_RAPPRESENTANTE","email":"mail@domain.com","cellulare":"34xxxxx018","ragione_sociale":"azienda test","cf_piva":"12345678910","comune":"roma","provincia":"RM","callback":false,"stato":"documenti_caricati","codice_registro_imprese":"openapi","documenti_registro_imprese":["60dc8da86c8b04624536bbb2_0_registro_imprese.p7m"],"owner":"mail@domain.com","timestamp":1625067055,"id":"60dc8da86c8b04624536bbb2"},"success":true,"message":"","error":null}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":353,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no request found","error":354,"data":null}}}},"406":{"description":"Not Acceptable","content":{"application/json":{"example":{"success":false,"message":"you can only upload documents when stato is 'in_attesa_di_documenti'","error":355,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"documenti required","error":356,"data":null}}}}}}},"/pec/{id}/modulo_attivazione":{"get":{"tags":["Modulistica"],"summary":"Download the activation form","description":"This method allows you to directly download the activation form of a certified e-mail. Once compiled and signed it will be passed in the form of a base 64 encoded string using the PATCH/pec/{id}/attivazione method together with an identity document.","parameters":[{"name":"id","in":"path","description":"request id","required":true,"schema":{"type":"string","example":"5f7b2e323a716857774a4373"}}],"responses":{"200":{"description":"A PDF file","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":201,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":202,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"you can activate the pec only when it is in the 'registrata|documenti_errati' state","error":267,"data":null}}}}}}},"/pec/{id}/modulo_conservazione":{"get":{"tags":["Modulistica"],"summary":"Download the activation form","description":"This method allows you to directly download the storage activation form for a certified e-mail. once compiled and signed it will be passed in the form of a base 64 encoded string using the PATCH/pec/{id}/conservazione method together with an identity document.","parameters":[{"name":"id","in":"path","description":"request id","required":true,"schema":{"type":"string","example":"5f7b2e323a716857774a4373"}}],"responses":{"200":{"description":"A PDF file","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":201,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":202,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"you can activate this service only if the pec has been processed","error":214,"data":null}}}}}}},"/comunica_pec/{id}/procura_registro_imprese":{"get":{"tags":["Modulistica"],"summary":"Download the power of attorney","description":"This method allows you to download the pec communication form to the business register. Once digitally signed in p7m format it will be passed in the form of a base 64 encoded string using the PATCH/comunica_pec/{id} method.","parameters":[{"name":"id","in":"path","description":"request id","required":true,"schema":{"type":"string","example":"5f7b2e323a716857774a4373"}}],"responses":{"200":{"description":"A PDF file","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"400":{"description":"Bad Request","content":{"application/json":{"example":{"success":false,"message":"Wrong id","error":201,"data":null}}}},"404":{"description":"Not Found","content":{"application/json":{"example":{"success":false,"message":"no pec found","error":202,"data":null}}}},"428":{"description":"Precondition Required","content":{"application/json":{"example":{"success":false,"message":"you can activate this service only if the pec has been processed","error":214,"data":null}}}}}}}},"externalDocs":{"description":"First time here? Generate a new access token","url":"https://console.openapi.com/oauth"},"security":[{"bearerAuth":[]}]}