attio-js
Version:
Developer-friendly & type-safe JS/TS SDK based on the official OpenAPI spec of Attio.
56 lines • 1.68 kB
JavaScript
/*
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
*/
import { objectsCreate } from "../funcs/objectsCreate.js";
import { objectsGet } from "../funcs/objectsGet.js";
import { objectsList } from "../funcs/objectsList.js";
import { objectsPartialUpdate } from "../funcs/objectsPartialUpdate.js";
import { ClientSDK } from "../lib/sdks.js";
import { unwrapAsync } from "../types/fp.js";
export class Objects extends ClientSDK {
/**
* List objects
*
* @remarks
* Lists all system-defined and user-defined objects in your workspace.
*
* Required scopes: `object_configuration:read`.
*/
async list(options) {
return unwrapAsync(objectsList(this, options));
}
/**
* Create an object
*
* @remarks
* Creates a new custom object in your workspace.
*
* Required scopes: `object_configuration:read-write`.
*/
async create(request, options) {
return unwrapAsync(objectsCreate(this, request, options));
}
/**
* Get an object
*
* @remarks
* Gets a single object by its `object_id` or slug.
*
* Required scopes: `object_configuration:read`.
*/
async get(request, options) {
return unwrapAsync(objectsGet(this, request, options));
}
/**
* Update an object
*
* @remarks
* Updates a single object. The object to be updated is identified by its `object_id`.
*
* Required scopes: `object_configuration:read-write`.
*/
async partialUpdate(request, options) {
return unwrapAsync(objectsPartialUpdate(this, request, options));
}
}
//# sourceMappingURL=objects.js.map