{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-products/namirialnotify/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown"},"seo":{"title":"Shared download APIs","description":"Integration and usage documentation."},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"shared-download-apis","__idx":0},"children":["Shared download APIs"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Some v1 download endpoints are shared across services. Use them when you already"," ","have affidavit or attachment IDs and need to retrieve the corresponding files."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The two resources use different response formats:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/AffidavitsDownload"]}," returns affidavit PDFs in a ZIP archive."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["/AttachmentDownload"]}," returns attachment metadata and Base64-encoded content in JSON."]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["For service-specific downloads, see the relevant service API reference, such as ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/products/namirialnotify/apis/evinotice-api"},"children":["EviNotice API"]},"."]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"download-affidavit-pdfs-by-id","__idx":1},"children":["Download affidavit PDFs by ID"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"POST /AffidavitsDownload\nGET /AffidavitsDownload\nHEAD /AffidavitsDownload\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Receives one or more affidavit identifiers and packages the corresponding PDF"," ","files in a ZIP archive. Obtain affidavit IDs from an ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["AffidavitPublished"]}," ","callback or from a service Query response that includes affidavit metadata."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The endpoint requires HTTP Basic authentication. It rejects the entire request"," ","if it contains an affidavit not owned by the authenticated user. Use POST or"," ","GET to retrieve the archive; the route also accepts HEAD with the same"," ","identifiers."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Request parameters:"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Field"},"children":["Field"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Location"},"children":["Location"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Required"},"children":["Required"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["UniqueIds"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["JSON body for POST; repeated query parameter for GET or HEAD"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Unique affidavit UUIDs. Do not repeat an ID. The configured maximum number of IDs can vary by deployment."]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Duplicate IDs are invalid. Correct the identifier list instead of retrying the"," ","same request unchanged."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Example POST request:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"curl -X POST \"https://api.evicertia.com/AffidavitsDownload\" \\\n  -u \"$EVI_USER:$EVI_PASS\" \\\n  -H \"Content-Type: application/json\" \\\n  --data '{\"UniqueIds\":[\"000c1f70-42ac-a3ea-149f-943879726a87\"]}' \\\n  --output affidavits.zip\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["A successful response has content type ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["application/zip"]}," and downloads as"," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["affidavits.zip"]},". Each PDF is stored in the archive as:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"<evidence-uuid>/<affidavit-uuid>.pdf\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The entire request fails if any requested affidavit does not exist or is not"," ","owned by the authenticated user."]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Response"},"children":["Response"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["200 OK"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["ZIP archive containing the requested affidavit PDFs."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["400 Bad Request"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["UniqueIds"]}," is missing or exceeds the deployment's configured limit."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["401 Unauthorized"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Authentication failed."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["403 Forbidden"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["The account lacks the required API permission, or one or more requested affidavits are not owned by the authenticated user."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["404 Not Found"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["One or more requested affidavit IDs do not exist."]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Callbacks and the standard affidavit metadata query options expose identifiers,"," ","not PDF bytes. The v1 Query contracts retain deprecated, single-result blob"," ","options for backward compatibility, but new integrations should use this"," ","endpoint when they need signed PDFs."]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"download-attachments-by-id","__idx":2},"children":["Download attachments by ID"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"POST /AttachmentDownload\nGET /AttachmentDownload\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Receives a list of attachment identifiers and returns attachment metadata and base64-encoded content."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Both operations require HTTP Basic authentication. Requests without valid"," ","credentials return ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["401 Unauthorized"]},"."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Request parameters:"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Field"},"children":["Field"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Location"},"children":["Location"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Required"},"children":["Required"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["UniqueIds"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["JSON body for POST; query parameter for GET"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Yes"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["List of attachment UUIDs to download."]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Response fields (v1 responses are camelCase):"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Field"},"children":["Field"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["results"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Collection of matching attachments (see fields below)."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["totalMatches"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Number of matching attachments found."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["responseStatus"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Error details when automatic exception handling returns one."]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Each attachment in ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["results"]}," contains:"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Field"},"children":["Field"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Type"},"children":["Type"]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"Description"},"children":["Description"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["uniqueId"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["UUID"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Unique identifier of the attachment."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["creationDate"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["date-time"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["When the attachment was created."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["evidenceUniqueId"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["UUID"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Identifier of the evidence it belongs to."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["partyId"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["UUID"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Identifier of the related party, when applicable."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contentId"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Content identifier."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["displayName"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Display name."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["filename"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["File name."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["mimeType"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["MIME type of the content."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contentDescription"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Content description."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contentDisposition"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Content disposition."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contentLocation"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Content location."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contentEncoding"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Content encoding."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["contentLength"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["integer"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Content length in bytes."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["hash"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Hash of the content (algorithm and value)."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["data"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["string"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Attachment content, Base64-encoded."]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["attributes"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["array"]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Optional key-value attributes; omitted when empty."]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Example response:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"json","header":{"controls":{"copy":{}}},"source":"{\n  \"results\": [\n    {\n      \"uniqueId\": \"000c1f70-42ac-a3ea-149f-943879726a87\",\n      \"creationDate\": \"2020-11-20T17:28:57.1880970+01:00\",\n      \"evidenceUniqueId\": \"000d1f70-42ac-a3ea-189f-943879726a87\",\n      \"contentId\": \"ee302292-8f64-479b-b5dd-ac79010f8895\",\n      \"displayName\": \"Attachment.pdf\",\n      \"filename\": \"Attachment.pdf\",\n      \"mimeType\": \"application/pdf\",\n      \"contentDisposition\": \"attachment; filename=\\\"Attachment.pdf\\\"\",\n      \"contentEncoding\": \"utf-8\",\n      \"contentLength\": 2960790,\n      \"hash\": \"{algorithm:SHA256,value:3/V5lRHf87BNUmWsFSOeeny0OUEUH8c8h2RgU0FjZp0=}\",\n      \"data\": \"<base64-encoded file content>\"\n    }\n  ],\n  \"totalMatches\": 1\n}\n","lang":"json"},"children":[]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"openapi-specification","__idx":3},"children":["OpenAPI specification"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Use the ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/products/namirialnotify/apis/oas/downloads-api"},"children":["shared download OpenAPI specification"]}," for a machine-readable definition of these endpoints."]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"related","__idx":4},"children":["Related"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/products/namirialnotify/apis/overview"},"children":["API reference overview"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/products/namirialnotify/apis/evinotice-api"},"children":["EviNotice API"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/products/namirialnotify/user-guides/evidences-affidavits"},"children":["Evidence and affidavits"]}]}]}]},"headings":[{"value":"Shared download APIs","id":"shared-download-apis","depth":1},{"value":"Download affidavit PDFs by ID","id":"download-affidavit-pdfs-by-id","depth":2},{"value":"Download attachments by ID","id":"download-attachments-by-id","depth":2},{"value":"OpenAPI specification","id":"openapi-specification","depth":2},{"value":"Related","id":"related","depth":2}],"frontmatter":{"title":"Shared download APIs","description":"REST API reference for shared affidavit and attachment download endpoints in Namirial Notify.","layout":"doc","outline":"deep","keywords":["affidavit download","attachment download","namirial notify api"],"seo":{"title":"Shared download APIs"}},"lastModified":"2026-08-21T12:44:22.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/products/namirialnotify/apis/downloads-api","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}