/** * Permit.io API * Authorization as a service * * The version of the OpenAPI document: 2.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios'; import { Configuration } from '../configuration'; import { RequestArgs, BaseAPI } from '../base'; import { RelationshipTupleCreate } from '../types'; import { RelationshipTupleDelete } from '../types'; import { RelationshipTupleRead } from '../types'; /** * RelationshipTuplesApi - axios parameter creator * @export */ export declare const RelationshipTuplesApiAxiosParamCreator: (configuration?: Configuration) => { /** * Create a relationship between two resource instances using a relation. * @summary Create Relationship Tuple * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {RelationshipTupleCreate} relationshipTupleCreate * @param {*} [options] Override http request option. * @throws {RequiredError} */ createRelationshipTuple: (projId: string, envId: string, relationshipTupleCreate: RelationshipTupleCreate, options?: AxiosRequestConfig) => Promise; /** * Delete a relationship between two resource instances. * @summary Delete Relationship Tuple * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {RelationshipTupleDelete} relationshipTupleDelete * @param {*} [options] Override http request option. * @throws {RequiredError} */ deleteRelationshipTuple: (projId: string, envId: string, relationshipTupleDelete: RelationshipTupleDelete, options?: AxiosRequestConfig) => Promise; /** * Lists the relationship tuples defined within an environment. * @summary List Relationship Tuples * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {number} [page] Page number of the results to fetch, starting at 1. * @param {number} [perPage] The number of results per page (max 100). * @param {*} [options] Override http request option. * @throws {RequiredError} */ listRelationshipTuples: (projId: string, envId: string, page?: number, perPage?: number, options?: AxiosRequestConfig) => Promise; }; /** * RelationshipTuplesApi - functional programming interface * @export */ export declare const RelationshipTuplesApiFp: (configuration?: Configuration) => { /** * Create a relationship between two resource instances using a relation. * @summary Create Relationship Tuple * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {RelationshipTupleCreate} relationshipTupleCreate * @param {*} [options] Override http request option. * @throws {RequiredError} */ createRelationshipTuple(projId: string, envId: string, relationshipTupleCreate: RelationshipTupleCreate, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Delete a relationship between two resource instances. * @summary Delete Relationship Tuple * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {RelationshipTupleDelete} relationshipTupleDelete * @param {*} [options] Override http request option. * @throws {RequiredError} */ deleteRelationshipTuple(projId: string, envId: string, relationshipTupleDelete: RelationshipTupleDelete, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Lists the relationship tuples defined within an environment. * @summary List Relationship Tuples * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {number} [page] Page number of the results to fetch, starting at 1. * @param {number} [perPage] The number of results per page (max 100). * @param {*} [options] Override http request option. * @throws {RequiredError} */ listRelationshipTuples(projId: string, envId: string, page?: number, perPage?: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>>; }; /** * RelationshipTuplesApi - factory interface * @export */ export declare const RelationshipTuplesApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => { /** * Create a relationship between two resource instances using a relation. * @summary Create Relationship Tuple * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {RelationshipTupleCreate} relationshipTupleCreate * @param {*} [options] Override http request option. * @throws {RequiredError} */ createRelationshipTuple(projId: string, envId: string, relationshipTupleCreate: RelationshipTupleCreate, options?: any): AxiosPromise; /** * Delete a relationship between two resource instances. * @summary Delete Relationship Tuple * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {RelationshipTupleDelete} relationshipTupleDelete * @param {*} [options] Override http request option. * @throws {RequiredError} */ deleteRelationshipTuple(projId: string, envId: string, relationshipTupleDelete: RelationshipTupleDelete, options?: any): AxiosPromise; /** * Lists the relationship tuples defined within an environment. * @summary List Relationship Tuples * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {number} [page] Page number of the results to fetch, starting at 1. * @param {number} [perPage] The number of results per page (max 100). * @param {*} [options] Override http request option. * @throws {RequiredError} */ listRelationshipTuples(projId: string, envId: string, page?: number, perPage?: number, options?: any): AxiosPromise>; }; /** * Request parameters for createRelationshipTuple operation in RelationshipTuplesApi. * @export * @interface RelationshipTuplesApiCreateRelationshipTupleRequest */ export interface RelationshipTuplesApiCreateRelationshipTupleRequest { /** * Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @type {string} * @memberof RelationshipTuplesApiCreateRelationshipTuple */ readonly projId: string; /** * Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @type {string} * @memberof RelationshipTuplesApiCreateRelationshipTuple */ readonly envId: string; /** * * @type {RelationshipTupleCreate} * @memberof RelationshipTuplesApiCreateRelationshipTuple */ readonly relationshipTupleCreate: RelationshipTupleCreate; } /** * Request parameters for deleteRelationshipTuple operation in RelationshipTuplesApi. * @export * @interface RelationshipTuplesApiDeleteRelationshipTupleRequest */ export interface RelationshipTuplesApiDeleteRelationshipTupleRequest { /** * Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @type {string} * @memberof RelationshipTuplesApiDeleteRelationshipTuple */ readonly projId: string; /** * Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @type {string} * @memberof RelationshipTuplesApiDeleteRelationshipTuple */ readonly envId: string; /** * * @type {RelationshipTupleDelete} * @memberof RelationshipTuplesApiDeleteRelationshipTuple */ readonly relationshipTupleDelete: RelationshipTupleDelete; } /** * Request parameters for listRelationshipTuples operation in RelationshipTuplesApi. * @export * @interface RelationshipTuplesApiListRelationshipTuplesRequest */ export interface RelationshipTuplesApiListRelationshipTuplesRequest { /** * Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @type {string} * @memberof RelationshipTuplesApiListRelationshipTuples */ readonly projId: string; /** * Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @type {string} * @memberof RelationshipTuplesApiListRelationshipTuples */ readonly envId: string; /** * Page number of the results to fetch, starting at 1. * @type {number} * @memberof RelationshipTuplesApiListRelationshipTuples */ readonly page?: number; /** * The number of results per page (max 100). * @type {number} * @memberof RelationshipTuplesApiListRelationshipTuples */ readonly perPage?: number; } /** * RelationshipTuplesApi - object-oriented interface * @export * @class RelationshipTuplesApi * @extends {BaseAPI} */ export declare class RelationshipTuplesApi extends BaseAPI { /** * Create a relationship between two resource instances using a relation. * @summary Create Relationship Tuple * @param {RelationshipTuplesApiCreateRelationshipTupleRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RelationshipTuplesApi */ createRelationshipTuple(requestParameters: RelationshipTuplesApiCreateRelationshipTupleRequest, options?: AxiosRequestConfig): Promise>; /** * Delete a relationship between two resource instances. * @summary Delete Relationship Tuple * @param {RelationshipTuplesApiDeleteRelationshipTupleRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RelationshipTuplesApi */ deleteRelationshipTuple(requestParameters: RelationshipTuplesApiDeleteRelationshipTupleRequest, options?: AxiosRequestConfig): Promise>; /** * Lists the relationship tuples defined within an environment. * @summary List Relationship Tuples * @param {RelationshipTuplesApiListRelationshipTuplesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof RelationshipTuplesApi */ listRelationshipTuples(requestParameters: RelationshipTuplesApiListRelationshipTuplesRequest, options?: AxiosRequestConfig): Promise>; }