UNPKG

nylas

Version:

A NodeJS wrapper for the Nylas REST API for email, contacts, and calendar.

72 lines (71 loc) 2.08 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.RedirectUris = void 0; const resource_js_1 = require("./resource.js"); const utils_js_1 = require("../utils.js"); /** * A collection of redirect URI related API endpoints. * * These endpoints allows for the management of redirect URIs. */ class RedirectUris extends resource_js_1.Resource { /** * Return all Redirect URIs * @return The list of Redirect URIs */ list({ overrides } = {}) { return super._list({ overrides, path: (0, utils_js_1.makePathParams)('/v3/applications/redirect-uris', {}), }); } /** * Return a Redirect URI * @return The Redirect URI */ find({ redirectUriId, overrides, }) { return super._find({ overrides, path: (0, utils_js_1.makePathParams)('/v3/applications/redirect-uris/{redirectUriId}', { redirectUriId, }), }); } /** * Create a Redirect URI * @return The created Redirect URI */ create({ requestBody, overrides, }) { return super._create({ overrides, path: (0, utils_js_1.makePathParams)('/v3/applications/redirect-uris', {}), requestBody, }); } /** * Update a Redirect URI * @return The updated Redirect URI */ update({ redirectUriId, requestBody, overrides, }) { return super._update({ overrides, path: (0, utils_js_1.makePathParams)('/v3/applications/redirect-uris/{redirectUriId}', { redirectUriId, }), requestBody, }); } /** * Delete a Redirect URI * @return The deleted Redirect URI */ destroy({ redirectUriId, overrides, }) { return super._destroy({ overrides, path: (0, utils_js_1.makePathParams)('/v3/applications/redirect-uris/{redirectUriId}', { redirectUriId, }), }); } } exports.RedirectUris = RedirectUris;