aYOUne
← Affiliate API

SearchBoxes

Singular: SearchBox — Base-URL: https://affiliate-api.ayoune.app — Zugriff: CRUD

play_circle Jetzt ausprobieren beta

Requests werden über den consumer-app Proxy an *.ayoune.app weitergeleitet. Tokens bleiben im Browser und werden pro Call mitgesendet.

Beispiel-Response (aufgezeichnet) Beispiel

Eine echte, zuvor aufgezeichnete GET /:id-Antwort dieses Endpunkts — nicht der Live-Call oben. Sensible Felder sind maskiert.

{
  "payload": {
    "_id": "65e07d8111cb6213d99d06bc",
    "type": "slider",
    "title": "Vergib einen Titel",
    "placeholder": "Vergib einen Titel",
    "background_color": "#FFFFFF",
    "border_color": "#000000",
    "border_radius": 0,
    "font_color": "#000000",
    "button_color": "#FF0000",
    "font_size": 10,
    "font_type": "Arial",
    "width": 350,
    "height": 300,
    "default_products": [],
    "categorys": "-,-",
    "brands": "-,-",
    "override": 1,
    "locale": "de_DE",
    "createdBy": "6045f4d25704710012485569",
    "createdAt": "2024-02-29T12:50:09.105Z",
    "updatedAt": "2024-02-29T12:50:09.105Z"
  },
  "meta": {
    "links": [
      {
        "rel": "self",
        "href": "https://affiliate-api.ayoune.app/searchboxes/65e07d8111cb6213d99d06bc",
        "method": "get",
        "title": "GET",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ]
      }
    ],
    "relations": [
      {
        "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": "6a62dbfd138b05b510db2995",
    "errors": [],
    "actions": [
      {
        "rel": "self",
        "action": "COPY",
        "title": "MODEL_SEARCHBOX",
        "href": "https://api.ayoune.app/affiliate/searchboxes/65e07d8111cb6213d99d06bc/copy",
        "method": "post",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ]
      },
      {
        "rel": "self",
        "action": "DELETE",
        "title": "MODEL_SEARCHBOX",
        "href": "https://api.ayoune.app/affiliate/searchboxes/65e07d8111cb6213d99d06bc/copy",
        "method": "post",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ]
      }
    ],
    "version": {
      "host": "2026.5.1",
      "core": "2026.257.1"
    },
    "rateLimit": {
      "limit": "2500",
      "remaining": "2334",
      "reset": "1784867314",
      "resetDate": "Fri Jul 24 2026"
    },
    "responseTime": 108.87806,
    "code": 200,
    "status": "success",
    "error": false
  }
}

Endpunkte

MethodePathBeschreibungRight
GET /searchboxes Liste mit Filtern/Paginierung affiliate.searchboxes.view
GET /searchboxes/:id Einzelner Datensatz affiliate.searchboxes.view
POST /searchboxes Neuen Datensatz erstellen affiliate.searchboxes.new
PUT /searchboxes Datensatz aktualisieren affiliate.searchboxes.edit
DELETE /searchboxes/:id Datensatz löschen affiliate.searchboxes.delete

SDK

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

// Alle abrufen
const list = await ay.affiliate.searchBoxes.find().limit(10).exec();

// Einzelnen Datensatz
const one = await ay.affiliate.searchBoxes.findById('OBJECT_ID').exec();

// Erstellen
const created = await ay.affiliate.searchBoxes.create({ name: 'Foo' });

Weiterführend