Skip to content

Upload an attachment

Request

Upload a file (image, PDF, document) to attachment storage. Use multipart/form-data. Returns an attachment UUID that can be used in attachments: [{ "uuid": "..." }] when sending LinkedIn messages or emails. Supported types include images (JPG, PNG, GIF), documents (PDF, DOCX), and other common formats.

Security
bearerAuth
Bodymultipart/form-datarequired
attachmentstring, (binary)required

The file to upload.

payloadobjectrequired
POST
/flows/api/attachments
curl -i -X POST \
  https://leadgen.grinfi.io/flows/api/attachments \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: multipart/form-data' \
  -F attachment=string \
  -F 'payload={"name":"photo.png","size":"324274","type":"image/png"}'

Responses

Attachment uploaded.

Bodyapplication/json
uuidstring

Attachment UUID.

team_idinteger
user_idinteger
payloadobject
bodystring or null
created_atstring, (date-time)
updated_atstring, (date-time)
Response
{ "uuid": "string", "team_id": 0, "user_id": 0, "payload": { "name": "photo.png", "path": "attachments/134/1ab98d82-cc1a-451b-918e-5b9c026a9d85.png", "size": "324274", "type": "image/png" }, "body": "string", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z" }