"use strict";
/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
Object.defineProperty(exports, "__esModule", { value: true });
exports.Results = void 0;
const resultsCreate_js_1 = require("../funcs/resultsCreate.js");
const resultsCreateForLineItem_js_1 = require("../funcs/resultsCreateForLineItem.js");
const resultsDelete_js_1 = require("../funcs/resultsDelete.js");
const resultsGet_js_1 = require("../funcs/resultsGet.js");
const resultsGetAll_js_1 = require("../funcs/resultsGetAll.js");
const resultsUpdate_js_1 = require("../funcs/resultsUpdate.js");
const sdks_js_1 = require("../lib/sdks.js");
const fp_js_1 = require("../types/fp.js");
const operations_js_1 = require("../types/operations.js");
class Results extends sdks_js_1.ClientSDK {
    /**
     * Get all Results
     *
     * @remarks
     * Get all of the results on the service provider.
     */
    async getAll(request, options) {
        return (0, operations_js_1.unwrapResultIterator)((0, resultsGetAll_js_1.resultsGetAll)(this, request, options));
    }
    /**
     * Create a Result
     *
     * @remarks
     * To create a new result. The request body must include a `result` object with the following required fields: `lineItem` (with sourcedId), `student` (with sourcedId), `scoreStatus`, and `scoreDate`. The responding system must return the set of sourcedIds that have been allocated to the newly created result records.
     */
    async create(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, resultsCreate_js_1.resultsCreate)(this, request, options));
    }
    /**
     * Get a Result
     *
     * @remarks
     * Get a specific result on the service provider. If the corresponding record cannot be located, the api will return a 404 error code and message 'Result not found.'
     */
    async get(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, resultsGet_js_1.resultsGet)(this, request, options));
    }
    /**
     * Update a Result
     *
     * @remarks
     * To update an existing result. The sourcedId for the record to be updated is supplied by the requesting system.
     */
    async update(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, resultsUpdate_js_1.resultsUpdate)(this, request, options));
    }
    /**
     * Delete a Result
     *
     * @remarks
     * Perform a soft delete on a specific Result on the service provider. This operation changes the status of the Result to 'tobedeleted'.
     */
    async delete(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, resultsDelete_js_1.resultsDelete)(this, request, options));
    }
    /**
     * Create a Result for a Line Item
     *
     * @remarks
     * To create a new result for a specific Line Item. The responding system must return the set of sourcedIds that have been allocated to the newly created result records. If the corresponding record cannot be located, the api will return a 404 error code and message 'Line item not found.'
     */
    async createForLineItem(request, options) {
        return (0, fp_js_1.unwrapAsync)((0, resultsCreateForLineItem_js_1.resultsCreateForLineItem)(this, request, options));
    }
}
exports.Results = Results;
//# sourceMappingURL=results.js.map