/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
import { resourcesCreate } from "../funcs/resourcesCreate.js";
import { resourcesDelete } from "../funcs/resourcesDelete.js";
import { resourcesGet } from "../funcs/resourcesGet.js";
import { resourcesGetAll } from "../funcs/resourcesGetAll.js";
import { resourcesUpdate } from "../funcs/resourcesUpdate.js";
import { ClientSDK } from "../lib/sdks.js";
import { unwrapAsync } from "../types/fp.js";
import { unwrapResultIterator } from "../types/operations.js";
import { ResourcesClasses } from "./resourcesclasses.js";
export class Resources extends ClientSDK {
    get classes() {
        return (this._classes ?? (this._classes = new ResourcesClasses(this._options)));
    }
    /**
     * Get all Resources
     *
     * @remarks
     * To get a collection of resources that exist on the service provider.
     */
    async getAll(request, options) {
        return unwrapResultIterator(resourcesGetAll(this, request, options));
    }
    /**
     * Create a new Resource
     *
     * @remarks
     * To create a new resource. The responding system must return the set of sourcedIds that have been allocated to the newly created resource record.
     */
    async create(request, options) {
        return unwrapAsync(resourcesCreate(this, request, options));
    }
    /**
     * Get a specific Resource
     *
     * @remarks
     * To get a specific resource by sourcedId. If the corresponding record cannot be located, the api will return a 404 error code and message 'Resource not found.'
     */
    async get(request, options) {
        return unwrapAsync(resourcesGet(this, request, options));
    }
    /**
     * Update an existing Resource
     *
     * @remarks
     * To update an existing resource. The sourcedId for the record to be updated is supplied by the requesting system.
     */
    async update(request, options) {
        return unwrapAsync(resourcesUpdate(this, request, options));
    }
    /**
     * Delete a resource
     *
     * @remarks
     * Perform a soft delete on a specific resource. This operation changes the status of the resource to 'tobedeleted'.
     */
    async delete(request, options) {
        return unwrapAsync(resourcesDelete(this, request, options));
    }
}
//# sourceMappingURL=resources.js.map