aYOUne
← HR API

MandatoryTasks

Singular: MandatoryTask — Base-URL: https://hr-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": "65e06d8a1e1be45a37c62471",
    "type": "task",
    "subject": "",
    "locking": false,
    "done": false,
    "approved": false,
    "archive": false,
    "createdBy": "6045f4d25704710012485569",
    "createdAt": "2024-02-29T11:42:02.728Z",
    "updatedAt": "2024-02-29T11:42:02.728Z"
  },
  "meta": {
    "links": [
      {
        "rel": "self",
        "href": "https://hr-api.ayoune.app/mandatorytasks/65e06d8a1e1be45a37c62471",
        "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"
      },
      {
        "rel": "Projects",
        "title": "MODEL_PROJECT",
        "href": "https://api.ayoune.app/pm/projects",
        "method": "get",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ],
        "right": "pm.projects"
      },
      {
        "rel": "Exams",
        "title": "MODEL_EXAM",
        "href": "https://api.ayoune.app/hub/exams",
        "method": "get",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ],
        "right": "hub.exams"
      },
      {
        "rel": "Tasks",
        "title": "MODEL_TASK",
        "href": "https://api.ayoune.app/pm/tasks",
        "method": "get",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ],
        "right": "pm.tasks"
      }
    ],
    "debugId": "6a62e02559e4802b7b80d491",
    "errors": [],
    "actions": [
      {
        "rel": "self",
        "action": "COPY",
        "title": "MODEL_MANDATORYTASK",
        "href": "https://api.ayoune.app/hr/mandatorytasks/65e06d8a1e1be45a37c62471/copy",
        "method": "post",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ]
      },
      {
        "rel": "self",
        "action": "DELETE",
        "title": "MODEL_MANDATORYTASK",
        "href": "https://api.ayoune.app/hr/mandatorytasks/65e06d8a1e1be45a37c62471/copy",
        "method": "post",
        "types": [
          "application/json",
          "application/yaml",
          "text/csv"
        ]
      }
    ],
    "version": {
      "host": "2026.11.0",
      "core": "2026.257.1"
    },
    "rateLimit": {
      "limit": "2500",
      "remaining": "2385",
      "reset": "1784868377",
      "resetDate": "Fri Jul 24 2026"
    },
    "responseTime": 86.042078,
    "code": 200,
    "status": "success",
    "error": false
  }
}

Endpunkte

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

SDK

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

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

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

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

Weiterführend