aYOUne
← Reporting API

NewsletterLinks

Singular: NewsletterLink — Base URL: https://reporting-api.ayoune.app — Access: CRUD

Example response (recorded) sample

A real, previously recorded GET /:id response of this endpoint — not the live call above. Sensitive fields are masked.

{
  "payload": {
    "_id": "65e0b1d0121b7d48fe15a172",
    "brands": [],
    "createdBy": "6045f4d25704710012485569",
    "createdAt": "2024-02-29T16:33:20.646Z",
    "updatedAt": "2024-02-29T16:33:20.646Z"
  },
  "meta": {
    "links": [
      {
        "rel": "self",
        "href": "https://reporting-api.ayoune.app/newsletterlinks/65e0b1d0121b7d48fe15a172",
        "method": "get",
        "title": "GET",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ]
      }
    ],
    "relations": [
      {
        "rel": "Newsletters",
        "title": "MODEL_NEWSLETTER",
        "href": "https://api.ayoune.app/marketing/newsletters",
        "method": "get",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ],
        "right": "marketing.newsletters"
      },
      {
        "rel": "Consumers",
        "title": "MODEL_CONSUMER",
        "href": "https://api.ayoune.app/crm/consumers",
        "method": "get",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ],
        "right": "crm.consumers"
      }
    ],
    "debugId": "6a6198e7c5e8aca9cc093d36",
    "errors": [],
    "actions": [
      {
        "rel": "self",
        "action": "COPY",
        "title": "MODEL_NEWSLETTERLINK",
        "href": "https://api.ayoune.app/reporting/newsletterlinks/65e0b1d0121b7d48fe15a172/copy",
        "method": "post",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ]
      },
      {
        "rel": "self",
        "action": "DELETE",
        "title": "MODEL_NEWSLETTERLINK",
        "href": "https://api.ayoune.app/reporting/newsletterlinks/65e0b1d0121b7d48fe15a172/copy",
        "method": "post",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ]
      }
    ],
    "version": {
      "host": "2026.24.0",
      "core": "2026.257.1"
    },
    "rateLimit": {
      "limit": "2500",
      "remaining": "2382",
      "reset": "1784784606",
      "resetDate": "Thu Jul 23 2026"
    },
    "responseTime": 201.701895,
    "code": 200,
    "status": "success",
    "error": false
  }
}

Endpoints

MethodPathDescriptionRight
GET /newsletterlinks List with filters/pagination reporting.newsletterlinks.view
GET /newsletterlinks/:id Single record reporting.newsletterlinks.view
POST /newsletterlinks Create new record reporting.newsletterlinks.new
PUT /newsletterlinks Update record reporting.newsletterlinks.edit
DELETE /newsletterlinks/:id Delete record reporting.newsletterlinks.delete

SDK

import { aYOUne } from '@tolinax/ayoune';
const ay = new aYOUne('pat_your_token');

// List all
const list = await ay.reporting.newsletterLinks.find().limit(10).exec();

// Single record
const one = await ay.reporting.newsletterLinks.findById('OBJECT_ID').exec();

// Create
const created = await ay.reporting.newsletterLinks.create({ name: 'Foo' });

See also