Skip to main content
GET
/
affiliate
/
campaigns
cURL
curl --request GET \
  --url https://api-beta.lomadee.com.br/affiliate/campaigns \
  --header 'x-api-key: <api-key>'
{
  "data": {
    "id": "<string>",
    "name": "<string>",
    "period": {
      "startAt": "<string>",
      "endAt": "<string>"
    },
    "type": "<string>",
    "offerType": "Spreadsheet",
    "categories": [
      "<string>"
    ],
    "description": "<string>",
    "code": "<string>",
    "url": "<string>",
    "organizationId": "<string>",
    "isHighlight": true,
    "status": "onTime",
    "createdAt": "<string>",
    "channels": [
      {
        "id": "<string>",
        "name": "<string>",
        "availableChannel": {
          "id": "<string>",
          "name": "<string>"
        },
        "shortUrls": [
          "<string>"
        ],
        "message": "<string>"
      }
    ],
    "mediaKit": {
      "banners": [
        "<string>"
      ],
      "emailMarketing": "<unknown>"
    }
  },
  "meta": {
    "total": 123,
    "page": 123,
    "limit": 123,
    "totalPages": 123
  }
}
Returns all campaigns from the system that the user has access to. Each campaign in the response includes a status field, automatically calculated based on the campaign’s period.startAt and period.endAt.

Authorizations

x-api-key
string
header
required

Query Parameters

page
integer<int32>

Page number for pagination

limit
integer<int32>

Maximum number of results per page

types
enum<string>[]

Campaign types to filter

Available options:
PersonalCoupon,
GenericCoupon,
Offer
offerType
enum<string>[]

Type of offer to filter. If not provided, all offers will be returned.

Spreadsheet: Spreadsheet offer type. In this case, links will not be generated automatically. You need to use the POST /affiliate/shortener/url endpoint to generate links by passing the campaign id as a parameter through featureId.

Url: Link offer type. In this case, links will be generated automatically.

Available options:
Spreadsheet,
Url
organizationId
string

Brand identifier to filter campaigns

organizationIds
string[]

List of brand identifiers to filter campaigns

name
string

Campaign name to search for

isHighlight
boolean

Filter campaigns by highlight status

categories
string[]

List of categories to filter campaigns

status
enum<string>[]

Filter campaigns by status. Accepts multiple values separated by comma.

onTime: Active campaign within period.

expired: Campaign expired (period.endAt has passed).

scheduled: Campaign scheduled (period.startAt has not arrived yet).

Example: status=onTime,expired

Available options:
onTime,
expired,
scheduled
period
object

Campaign period filter

startAt
string<date-time>

Campaign start date (ISO 8601). Must be used together with endAt.

endAt
string<date-time>

Campaign end date (ISO 8601). Must be used together with startAt.

Response

200 - application/json

Campaign response

data
object
meta
object