/
PUT v2/EviNotice/Batches/{batchid}/Attachments

PUT v2/EviNotice/Batches/{batchid}/Attachments

HTTP Method: PUT

Description:

This endpoint allows adding attachments to be included in each EviNoticesent as part of a bulk email batch. The batchid parameter in the URL is the identifier returned by the initial batch creation endpoint.
As this is a PUT method, every call will overwrite all previously set attachments. Therefore, all attachments must be sent in a single request.

Input Parameters

  • Attachments (IEnumerable<Attachment>): A collection of attachments to include in the batch. Each attachment must contain the following properties:

    • DisplayName (string): Descriptive text defining the file content.

    • FileName (string): The name of the file.

    • Data (string): The file content encoded in Base64 format.

    • Attributes (IEnumerable<KeyValue>, optional): Array of key-value pairs specifying additional attributes for the attachment.

      • Key (string): Identifier for the attribute.

      • Value/Values (string/string[]): Value or array of values for the specified key.

Output Parameters

  • No output parameters. The endpoint will only return an HTTP status code indicating the result of the operation.

Request Example

PUT /v2/EviNotice/Batches/{batchid}/Attachments Content-Type: application/json Authorization: Bearer YOUR_ACCESS_TOKEN { "Attachments": [ { "DisplayName": "Terms and Conditions", "FileName": "terms_and_conditions.pdf", "Data": "JVBERi0xLjQKJcfs...Base64EncodedContent...", "Attributes": [ { "Key": "Type", "Value": "PDF" }, { "Key": "Category", "Value": ["Legal", "Mandatory"] } ] }, { "DisplayName": "User Guide", "FileName": "user_guide.pdf", "Data": "JVBERi0xLjQKJcfs...Base64EncodedContent...", "Attributes": [ { "Key": "Type", "Value": "PDF" } ] } ] }

Response Example

The endpoint will return an HTTP status code:

  • 200 OK if the attachments were successfully set.

  • 400 Bad Request if the input was invalid.

  • 404 Not Found if the specified batchid does not exist.

Notes

  • Overwriting Attachments:

    • To remove all previously uploaded attachments, make a call to this endpoint with an empty array as the Attachments parameter.

    • Example:

      { "Attachments": [] }
  • Base64 Encoding:

    • The Data field must contain the file's content encoded in Base64 format.

  • Batch ID Requirement:

    • The batchid in the URL must correspond to an existing batch created via the initial Submit endpoint.

Related content

GET v2/EviMail/Batches/{batchid}
GET v2/EviMail/Batches/{batchid}
More like this
PUT v2/EviMail/Batches/{batchid}/Body
PUT v2/EviMail/Batches/{batchid}/Body
More like this
EviNotice Batch Sending
EviNotice Batch Sending
More like this
GET v2/EviNotice/Batches/{batchid}
GET v2/EviNotice/Batches/{batchid}
More like this
PUT v2/EviNotice/Batches/{batchid}/Body
PUT v2/EviNotice/Batches/{batchid}/Body
More like this
POST v2/EviNotice/Batches
POST v2/EviNotice/Batches
More like this