aYOUne
← Sales API

Lots

Singular: Lot — Base URL: https://sale-api.ayoune.app — Access: CRUD

play_circle Try it now beta

Requests are proxied through the consumer-app to *.ayoune.app. Tokens stay in your browser and are forwarded per call.

Endpoints

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

SDK

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

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

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

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

See also