CampaignFlow.Client.Attachments (CampaignFlow Client v2.0.0)

View Source

Attachment resource operations for the Campaign Flow API.

Attachments represent metadata for files that have been uploaded and attached to entities in the system.

Summary

Functions

Attaches a previously uploaded asset to an entity.

Deletes an attachment.

Retrieves attachment metadata by ID.

Lists attachment metadata.

Functions

create(client, params)

Attaches a previously uploaded asset to an entity.

Examples

{:ok, attachment} = CampaignFlow.Client.Attachments.create(client, %{
  asset_id: 456,
  entity_type: "campaign",
  entity_id: 789
})

delete(client, id)

Deletes an attachment.

Examples

{:ok, response} = CampaignFlow.Client.Attachments.delete(client, 123)

get(client, id)

Retrieves attachment metadata by ID.

Examples

{:ok, attachment} = CampaignFlow.Client.Attachments.get(client, 123)

list(client, params \\ [])

Lists attachment metadata.

Options

  • :page - Page number for pagination
  • :per_page - Number of items per page

Examples

{:ok, attachments} = CampaignFlow.Client.Attachments.list(client)