@vercel/sdk
Version:
<p align="center"> <a href="https://vercel.com"> <img src="https://assets.vercel.com/image/upload/v1588805858/repositories/vercel/logo.png" height="96"> <h3 align="center">Vercel</h3> </a> <p align="center">Develop. Preview. Ship.</p> </p>
68 lines • 2.91 kB
JavaScript
/*
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
*/
import { aliasesAssignAlias } from "../funcs/aliasesAssignAlias.js";
import { aliasesDeleteAlias } from "../funcs/aliasesDeleteAlias.js";
import { aliasesGetAlias } from "../funcs/aliasesGetAlias.js";
import { aliasesListAliases } from "../funcs/aliasesListAliases.js";
import { aliasesListDeploymentAliases } from "../funcs/aliasesListDeploymentAliases.js";
import { aliasesPatchUrlProtectionBypass } from "../funcs/aliasesPatchUrlProtectionBypass.js";
import { ClientSDK } from "../lib/sdks.js";
import { unwrapAsync } from "../types/fp.js";
export class Aliases extends ClientSDK {
/**
* List Deployment Aliases
*
* @remarks
* Retrieves all Aliases for the Deployment with the given ID. The authenticated user or team must own the deployment.
*/
async listDeploymentAliases(request, options) {
return unwrapAsync(aliasesListDeploymentAliases(this, request, options));
}
/**
* Assign an Alias
*
* @remarks
* Creates a new alias for the deployment resolved from the given deployment or alias ID or URL. The authenticated user or team must own this deployment. If the desired alias is already assigned to another deployment, then it will be removed from the old deployment and assigned to the new one.
*/
async assignAlias(request, options) {
return unwrapAsync(aliasesAssignAlias(this, request, options));
}
/**
* List aliases
*
* @remarks
* Retrieves a list of aliases for the authenticated User or Team. When `domain` is provided, only aliases for that domain will be returned. When `projectId` is provided, it will only return the given project aliases.
*/
async listAliases(request, options) {
return unwrapAsync(aliasesListAliases(this, request, options));
}
/**
* Get an Alias
*
* @remarks
* Retrieves an Alias for the given host name or alias ID.
*/
async getAlias(request, options) {
return unwrapAsync(aliasesGetAlias(this, request, options));
}
/**
* Delete an Alias
*
* @remarks
* Delete an Alias with the specified ID.
*/
async deleteAlias(request, options) {
return unwrapAsync(aliasesDeleteAlias(this, request, options));
}
/**
* Update the protection bypass for a URL
*
* @remarks
* Update the protection bypass for the alias or deployment URL (used for user access & comment access for deployments). Used as shareable links and user scoped access for Vercel Authentication and also to allow external (logged in) people to comment on previews for Preview Comments (next-live-mode).
*/
async patchUrlProtectionBypass(request, options) {
return unwrapAsync(aliasesPatchUrlProtectionBypass(this, request, options));
}
}
//# sourceMappingURL=aliases.js.map