/* tslint:disable */
import {
  AbacAttribute,
  AcceptAppInviteRequest,
  AcceptAppInviteResponse,
  AcceptInviteRequest,
  AcceptInviteResponse,
  AccountPartialPath,
  AccountPolicyAssignment,
  AccountResourceContext,
  AccountResourceContextV2,
  AccountWithRoles,
  ActionsFilter,
  AddStatementToPolicyRequest,
  AddStatementToPolicyResponse,
  AllResources,
  AllSitesForAccount,
  And,
  AppInvite,
  ApplicationError,
  AssignPoliciesRequest,
  AssignPoliciesResponse,
  AssignPoliciesToTeamMemberRequest,
  AssignPoliciesToTeamMemberResponse,
  AssignPolicyResponse,
  Assignment,
  AssignmentData,
  AssignmentUpdateField,
  AttributeUpdateResourceResult,
  AttributeUpdateWithOperatorResult,
  AttributeValue,
  AttributesOperator,
  AuthorizationEmptyResponse,
  AuthorizationRequest,
  AuthorizationResponse,
  AuthorizationSiteOwner,
  BackOfficeIsPermitted,
  BoolValue,
  BooleanLiteral,
  BulkActionMetadata,
  BulkBackOfficeIsPermittedRequest,
  BulkGetPermittedSubjectsCountRequest,
  BulkGetPermittedSubjectsCountResponse,
  BulkGetSubjectRolesRequest,
  BulkGetSubjectRolesResponse,
  BulkIsPermittedRequest,
  BulkIsPermittedResponse,
  BulkIsPolicyAssignedRequest,
  BulkIsPolicyAssignedResponse,
  BulkOverrideSubjectPoliciesRequest,
  BulkOverrideSubjectPoliciesResponse,
  BulkResourceAttributeUpdateRequest,
  BulkResourceAttributeUpdateResponse,
  BulkSubjectBackOfficeIsPermittedRequest,
  BulkSubjectIsPermittedResponse,
  BulkSubjectPoliciesResult,
  BulkUpdateResourcesWithAttributeRequest,
  BulkUpdateResourcesWithAttributeResponse,
  ByPermissions,
  ChangeInvitePoliciesRequest,
  ChangePolicyOwnerRequest,
  ChangePolicyOwnerResponse,
  ClearAssignedAppPoliciesRequest,
  ClearAssignedAppPoliciesResponse,
  ClearAssignedPoliciesRequest,
  ClearAssignedPoliciesResponse,
  ClearTeamMemberPoliciesRequest,
  ClearTeamMemberPoliciesResponse,
  ConditionAttributeType,
  ConditionOperator,
  ConditionType,
  ConditionUpdate,
  ConditionValue,
  ConsistencyLevel,
  Contributor,
  ContributorLimit,
  CreateAppInviteRequest,
  CreateAppInviteResponse,
  CreateInviteRequest,
  CreateInviteResponse,
  CreatePolicyRequest,
  CreatePolicyResponse,
  CustomResource,
  DeleteAccountInviteRequest,
  DeleteAccountInvitesRequest,
  DeleteAppInviteRequest,
  DeleteAppInviteResponse,
  DeleteAssignmentsRequest,
  DeleteAssignmentsResponse,
  DeleteAttributesByTenantRequest,
  DeleteInviteRequest,
  DeletePolicyRequest,
  DeletePolicyResponse,
  DeletePolicyStatementRequest,
  DeletePolicyStatementResponse,
  DeleteTeamMemberAssignmentsRequest,
  DeleteTeamMemberAssignmentsResponse,
  DependOnOperator,
  DevAssignPolicyRequest,
  DevEmptyResponse,
  DevPolicyPermissions,
  Effect,
  EnvironmentCondition,
  EqAttr,
  EqLiteral,
  EqualOperator,
  ExactMatch,
  ExperimentCondition,
  ExperimentOperator,
  Field,
  FieldMask,
  FilterPoliciesRequest,
  FilterPoliciesResponse,
  FixTeamMemberAssignmentsRequest,
  FoldExperimentRequest,
  FoldExperimentResponse,
  ForceDeleteAssignmentsRequest,
  ForceDeleteAssignmentsResponse,
  FullNameResource,
  GetAppInviteRequest,
  GetAppInviteResponse,
  GetAppInvitesRequest,
  GetAppInvitesResponse,
  GetAssignmentsRequest,
  GetAssignmentsResponse,
  GetAttributesRequest,
  GetAttributesResponse,
  GetBulkSubjectPoliciesBySubjectContextRequest,
  GetBulkSubjectPoliciesBySubjectContextResponse,
  GetContainedPoliciesRequest,
  GetContainedPoliciesResponse,
  GetCurrentSubjectContainedPoliciesRequest,
  GetCurrentSubjectContainedPoliciesResponse,
  GetCurrentSubjectPermissionsOnResourceRequest,
  GetCurrentSubjectPermissionsOnResourceResponse,
  GetCurrentSubjectPermissionsOnResourcesRequest,
  GetCurrentSubjectPermissionsOnResourcesResponse,
  GetInviteRequest,
  GetInviteResponse,
  GetInvitesByAccountRequest,
  GetInvitesByAccountResponse,
  GetPermissionsRequest,
  GetPermissionsResponse,
  GetPermittedSubjectsRolesRequest,
  GetPermittedSubjectsRolesResponse,
  GetPermittedSubjectsStatementsRequest,
  GetPermittedSubjectsStatementsResponse,
  GetPoliciesApplicableRestrictionsRequest,
  GetPoliciesApplicableRestrictionsResponse,
  GetPoliciesAssignedOnResourceFilter,
  GetPoliciesAssignedOnResourceRequest,
  GetPoliciesAssignedOnResourceResponse,
  GetPoliciesMissingSubPoliciesPermissionsRequest,
  GetPoliciesMissingSubPoliciesPermissionsResponse,
  GetPoliciesPermissionsRequest,
  GetPoliciesPermissionsResponse,
  GetPoliciesScopeDiffsRequest,
  GetPoliciesScopesDiffResponse,
  GetRestrictedSubjectsRequest,
  GetRestrictedSubjectsResponse,
  GetRestrictionsRequest,
  GetRestrictionsResponse,
  GetSubjectAssignedPoliciesRequest,
  GetSubjectAssignedPoliciesResponse,
  GetSubjectPermissionsOnResourceRequest,
  GetSubjectPermissionsOnResourceResponse,
  GetSubjectPermittedResourcesRequest,
  GetSubjectPermittedResourcesResponse,
  GetSubjectPermittingAssignmentsRequest,
  GetSubjectPermittingAssignmentsResponse,
  GetSubjectPoliciesBySubjectContextRequest,
  GetSubjectPoliciesBySubjectContextResponse,
  GetSubjectPoliciesOnCurrentAccountRequest,
  GetSubjectPoliciesOnCurrentAccountResponse,
  GetSubjectRolesRequest,
  GetSubjectRolesResponse,
  HardDeleteStatementRequest,
  HardDeleteStatementResponse,
  ImplicitIsPermittedRequest,
  Invite,
  InviteAccount,
  InviteAssignmentResource,
  InviteData,
  InviteFilter,
  InviteFullNameResource,
  InviteInviteAssignment,
  InviteInviteResourceAssignment,
  InviteReq,
  InviteSite,
  IsPermittedByAppInstanceRequest,
  IsPermittedRequest,
  IsPermittedResource,
  IsPermittedResponse,
  IsPolicyAssigned,
  ItemMetadata,
  JoinedCondition,
  JoinedConditionOperator,
  KindListValue,
  LegacyPermission,
  Like,
  LikeOperator,
  MailAndAccountId,
  ManagementAssignPolicyRequest,
  ManagementCondition,
  ManagementGetPoliciesRequest,
  ManagementGetPoliciesResponse,
  ManagementGetPolicyRequest,
  ManagementGetPolicyResponse,
  MigrateInviteRequest,
  MissingPermissions,
  ModelAttribute,
  NoCondition,
  NullValue,
  NumberValue,
  Or,
  OrganizationPartialPath,
  OrganizationResourceContext,
  Paging,
  PermissionPolicies,
  PermissionsFilter,
  PermissionsFilteredPolicies,
  PermittedResource,
  Policy,
  PolicyAssignment,
  PolicyCondition,
  PolicyData,
  PolicyMissingPermissions,
  PolicyRestrictions,
  PolicyStatement,
  PolicyType,
  QueryCondition,
  QueryGetPoliciesRequest,
  QueryGetPoliciesResponse,
  QueryGetPolicyRequest,
  QueryGetPolicyResponse,
  QueryPolicyPermissions,
  ReplaceAllAssignedPoliciesConditionRequest,
  ReplaceAllAssignedPoliciesConditionResponse,
  ReplaceAllAssignedPoliciesRequest,
  ReplaceAllAssignedPoliciesResponse,
  ReplaceAllTeamMemberPoliciesRequest,
  ReplaceAllTeamMemberPoliciesResponse,
  ReplaceTeamMemberPoliciesRequest,
  ReplaceTeamMemberPoliciesResponse,
  ResetAppInviteRequest,
  ResetAppInviteResponse,
  ResetInviteRequest,
  ResetInviteResponse,
  Resource,
  ResourceAssignment,
  ResourceAttributeUpdate,
  ResourceAttributeUpdateEvent,
  ResourceContext,
  ResourceContributorCount,
  ResourceEntity,
  ResourceFilter,
  ResourceIsPermitted,
  ResourcePermissions,
  ResourceResponse,
  ResourceType,
  ResourceUpdate,
  ResourceWithOwner,
  RestrictedResource,
  RestrictedSubject,
  RestrictedTeamMember,
  Role,
  RolesOnResource,
  RunSingleMigrationRequest,
  RunSingleMigrationResponse,
  ServiceEmptyResponse,
  ServiceInviteAssignment,
  ServiceInviteResourceAssignment,
  SetAttribute,
  SimpleCondition,
  SimpleConditionOperator,
  SimpleConditionValue,
  Site,
  SiteAccountsWithRoles,
  SitePartialPath,
  SitePolicyAssignment,
  SiteResourceContext,
  SiteRestrictedSubjects,
  SiteUsersWithRoles,
  StartsWith,
  Statement,
  StringLiteral,
  StringValue,
  StructListValue,
  StructValue,
  Subject,
  SubjectAssignment,
  SubjectAssignments,
  SubjectContext,
  SubjectContextType,
  SubjectIsPermitted,
  SubjectPolicies,
  SubjectRoles,
  SubjectType,
  SubjectTypesFilter,
  SubjectView,
  TriggerGdprDeleteUserDataRequest,
  TriggerGdprDeleteUserDataResponse,
  UnassignPolicyFromSubjectRequest,
  UnassignPolicyFromSubjectResponse,
  UnknownFieldSet,
  UnsetAttribute,
  UpdateAssignmentRequest,
  UpdateAssignmentResponse,
  UpdateAttribute,
  UpdateFailure,
  UpdateInviteAssignmentsRequest,
  UpdatePoliciesOnSiteTransferRequest,
  UpdatePoliciesOnSiteTransferResponse,
  UpdatePolicyAuthorizationDataRequest,
  UpdatePolicyMetadataRequest,
  UpdatePolicyResponse,
  UpdateResourcesWithAttributeMessage,
  UpdateResult,
  UpdateSiteContextAssignmentsRequest,
  UpdateSiteContextAssignmentsResponse,
  UpdateSuccess,
  UserWithRoles,
} from './types';

import { AmbassadorHTTPClient, AmbassadorHTTPClientConfig } from '@wix/ambassador/runtime/http';

import { AxiosInstance } from 'axios';
export const AuthorizationServer = (baseUrl: string, httpClientConfig?: AmbassadorHTTPClientConfig) => {
  const httpClient = new AmbassadorHTTPClient(baseUrl, httpClientConfig);

  return {
    AbacAttributesService: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          bulkUpdateResourceAttribute: (bulkResourceAttributeUpdateRequest: BulkResourceAttributeUpdateRequest): Promise<BulkResourceAttributeUpdateResponse> =>
            httpClient.invoke('PUT', '/v1/attributes/bulk', bulkResourceAttributeUpdateRequest, headers),
          bulkUpdateResourcesWithAttribute: (bulkUpdateResourcesWithAttributeRequest: BulkUpdateResourcesWithAttributeRequest): Promise<BulkUpdateResourcesWithAttributeResponse> =>
            httpClient.invoke('PUT', '/v1/attributes/resources/bulk', bulkUpdateResourcesWithAttributeRequest, headers),
          deleteAttributesByTenant: (deleteAttributesByTenantRequest: DeleteAttributesByTenantRequest): Promise<any> =>
            httpClient.invoke('DELETE', '/v1/attributes/{tenant}', deleteAttributesByTenantRequest, headers),
          getAttributes: (getAttributesRequest: GetAttributesRequest): Promise<GetAttributesResponse> => httpClient.invoke('GET', '/v1/attributes', getAttributesRequest, headers),
          updateResourceAttribute: (resourceAttributeUpdate: ResourceAttributeUpdate): Promise<any> => httpClient.invoke('PUT', '/v1/attributes', resourceAttributeUpdate, headers),
          updateResourcesWithAttribute: (updateResourcesWithAttributeMessage: UpdateResourcesWithAttributeMessage): Promise<any> =>
            httpClient.invoke('PUT', '/v1/attributes/resources', updateResourcesWithAttributeMessage, headers),
        };
        (service as any).bulkUpdateResourceAttribute.__http_method = 'PUT';
        (service as any).bulkUpdateResourceAttribute.__http_url = '/v1/attributes/bulk';
        (service as any).bulkUpdateResourcesWithAttribute.__http_method = 'PUT';
        (service as any).bulkUpdateResourcesWithAttribute.__http_url = '/v1/attributes/resources/bulk';
        (service as any).deleteAttributesByTenant.__http_method = 'DELETE';
        (service as any).deleteAttributesByTenant.__http_url = '/v1/attributes/{tenant}';
        (service as any).getAttributes.__http_method = 'GET';
        (service as any).getAttributes.__http_url = '/v1/attributes';
        (service as any).updateResourceAttribute.__http_method = 'PUT';
        (service as any).updateResourceAttribute.__http_url = '/v1/attributes';
        (service as any).updateResourcesWithAttribute.__http_method = 'PUT';
        (service as any).updateResourcesWithAttribute.__http_url = '/v1/attributes/resources';
        return service;
      };
    },
    AbacAuthorizationDevService: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          getPoliciesMissingSubPoliciesPermissions: (
            getPoliciesMissingSubPoliciesPermissionsRequest: GetPoliciesMissingSubPoliciesPermissionsRequest
          ): Promise<GetPoliciesMissingSubPoliciesPermissionsResponse> =>
            httpClient.invoke('GET', '/v1/dev/policies/missing_permissions', getPoliciesMissingSubPoliciesPermissionsRequest, headers),
        };
        (service as any).getPoliciesMissingSubPoliciesPermissions.__http_method = 'GET';
        (service as any).getPoliciesMissingSubPoliciesPermissions.__http_url = '/v1/dev/policies/missing_permissions';
        return service;
      };
    },
    AbacAuthorizationService: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          bulkIsPermitted: (bulkIsPermittedRequest: BulkIsPermittedRequest): Promise<BulkIsPermittedResponse> =>
            httpClient.invoke('POST', '/v1/authorization/bulk/is_permitted', bulkIsPermittedRequest, headers),
          getRestrictions: (getRestrictionsRequest: GetRestrictionsRequest): Promise<GetRestrictionsResponse> =>
            httpClient.invoke('GET', '/v1/authorization/has_restrictions', getRestrictionsRequest, headers),
          implicitIsPermitted: (implicitIsPermittedRequest: ImplicitIsPermittedRequest): Promise<IsPermittedResponse> =>
            httpClient.invoke('GET', '/v1/authorization/implicit_is_permitted', implicitIsPermittedRequest, headers),
          isPermitted: (isPermittedRequest: IsPermittedRequest): Promise<IsPermittedResponse> =>
            httpClient.invoke('POST', '/v1/authorization/is_permitted', isPermittedRequest, headers),
        };
        (service as any).bulkIsPermitted.__http_method = 'POST';
        (service as any).bulkIsPermitted.__http_url = '/v1/authorization/bulk/is_permitted';
        (service as any).getRestrictions.__http_method = 'GET';
        (service as any).getRestrictions.__http_url = '/v1/authorization/has_restrictions';
        (service as any).implicitIsPermitted.__http_method = 'GET';
        (service as any).implicitIsPermitted.__http_url = '/v1/authorization/implicit_is_permitted';
        (service as any).isPermitted.__http_method = 'POST';
        (service as any).isPermitted.__http_url = '/v1/authorization/is_permitted';
        return service;
      };
    },
    AbacManagementService: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          addStatementToPolicy: (addStatementToPolicyRequest: AddStatementToPolicyRequest): Promise<AddStatementToPolicyResponse> =>
            httpClient.invoke('PUT', '/v1/policies/predefined/{policy_id}/add-statement', addStatementToPolicyRequest, headers),
          assignPolicy: (managementAssignPolicyRequest: ManagementAssignPolicyRequest): Promise<AssignPolicyResponse> =>
            httpClient.invoke('POST', '/v1/policies/{policy_id}/assignments', managementAssignPolicyRequest, headers),
          createPolicy: (createPolicyRequest: CreatePolicyRequest): Promise<CreatePolicyResponse> =>
            httpClient.invoke('POST', '/v1/policies/predefined', createPolicyRequest, headers),
          deleteAssignments: (deleteAssignmentsRequest: DeleteAssignmentsRequest): Promise<DeleteAssignmentsResponse> =>
            httpClient.invoke('DELETE', '/v1/policies/assignments', deleteAssignmentsRequest, headers),
          deletePolicy: (deletePolicyRequest: DeletePolicyRequest): Promise<DeletePolicyResponse> =>
            httpClient.invoke('DELETE', '/v1/policies/predefined/{policy_id}', deletePolicyRequest, headers),
          deletePolicyStatement: (deletePolicyStatementRequest: DeletePolicyStatementRequest): Promise<DeletePolicyStatementResponse> =>
            httpClient.invoke('DELETE', '/v1/statements/{statement_id}', deletePolicyStatementRequest, headers),
          foldExperiment: (foldExperimentRequest: FoldExperimentRequest): Promise<FoldExperimentResponse> =>
            httpClient.invoke('POST', '/v1/policies/experiments/{policy_id}/fold', foldExperimentRequest, headers),
          getPolicies: (managementGetPoliciesRequest: ManagementGetPoliciesRequest): Promise<ManagementGetPoliciesResponse> =>
            httpClient.invoke('GET', '/v1/management/policies', managementGetPoliciesRequest, headers),
          getPolicy: (managementGetPolicyRequest: ManagementGetPolicyRequest): Promise<ManagementGetPolicyResponse> =>
            httpClient.invoke('GET', '/v1/policies/{policy_id}', managementGetPolicyRequest, headers),
          unassignPolicyFromSubject: (unassignPolicyFromSubjectRequest: UnassignPolicyFromSubjectRequest): Promise<UnassignPolicyFromSubjectResponse> =>
            httpClient.invoke('DELETE', '/v1/policies/{policy_id}/assignments/subject/{subject.id}', unassignPolicyFromSubjectRequest, headers),
          updateAssignment: (updateAssignmentRequest: UpdateAssignmentRequest): Promise<UpdateAssignmentResponse> =>
            httpClient.invoke('PUT', '/v1/policies/assignments', updateAssignmentRequest, headers),
          updatePolicyAuthorizationData: (updatePolicyAuthorizationDataRequest: UpdatePolicyAuthorizationDataRequest): Promise<UpdatePolicyResponse> =>
            httpClient.invoke('PUT', '/v1/policies/predefined/{policy_id}/authorization-data', updatePolicyAuthorizationDataRequest, headers),
          updatePolicyMetadata: (updatePolicyMetadataRequest: UpdatePolicyMetadataRequest): Promise<UpdatePolicyResponse> =>
            httpClient.invoke('PATCH', '/v1/policies/predefined/{policy_id}/metadata', updatePolicyMetadataRequest, headers),
        };
        (service as any).addStatementToPolicy.__http_method = 'PUT';
        (service as any).addStatementToPolicy.__http_url = '/v1/policies/predefined/{policy_id}/add-statement';
        (service as any).assignPolicy.__http_method = 'POST';
        (service as any).assignPolicy.__http_url = '/v1/policies/{policy_id}/assignments';
        (service as any).createPolicy.__http_method = 'POST';
        (service as any).createPolicy.__http_url = '/v1/policies/predefined';
        (service as any).deleteAssignments.__http_method = 'DELETE';
        (service as any).deleteAssignments.__http_url = '/v1/policies/assignments';
        (service as any).deletePolicy.__http_method = 'DELETE';
        (service as any).deletePolicy.__http_url = '/v1/policies/predefined/{policy_id}';
        (service as any).deletePolicyStatement.__http_method = 'DELETE';
        (service as any).deletePolicyStatement.__http_url = '/v1/statements/{statement_id}';
        (service as any).foldExperiment.__http_method = 'POST';
        (service as any).foldExperiment.__http_url = '/v1/policies/experiments/{policy_id}/fold';
        (service as any).getPolicies.__http_method = 'GET';
        (service as any).getPolicies.__http_url = '/v1/management/policies';
        (service as any).getPolicy.__http_method = 'GET';
        (service as any).getPolicy.__http_url = '/v1/policies/{policy_id}';
        (service as any).unassignPolicyFromSubject.__http_method = 'DELETE';
        (service as any).unassignPolicyFromSubject.__http_url = '/v1/policies/{policy_id}/assignments/subject/{subject.id}';
        (service as any).updateAssignment.__http_method = 'PUT';
        (service as any).updateAssignment.__http_url = '/v1/policies/assignments';
        (service as any).updatePolicyAuthorizationData.__http_method = 'PUT';
        (service as any).updatePolicyAuthorizationData.__http_url = '/v1/policies/predefined/{policy_id}/authorization-data';
        (service as any).updatePolicyMetadata.__http_method = 'PATCH';
        (service as any).updatePolicyMetadata.__http_url = '/v1/policies/predefined/{policy_id}/metadata';
        return service;
      };
    },
    AbacQueryService: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          bulkIsPolicyAssigned: (bulkIsPolicyAssignedRequest: BulkIsPolicyAssignedRequest): Promise<BulkIsPolicyAssignedResponse> =>
            httpClient.invoke('GET', '/query/v1/policies/assigned', bulkIsPolicyAssignedRequest, headers),
          filterPolicies: (filterPoliciesRequest: FilterPoliciesRequest): Promise<FilterPoliciesResponse> =>
            httpClient.invoke('GET', '/query/v1/policies/filter', filterPoliciesRequest, headers),
          getAssignments: (getAssignmentsRequest: GetAssignmentsRequest): Promise<GetAssignmentsResponse> =>
            httpClient.invoke('GET', '/v1/assignments/{assignment_ids}', getAssignmentsRequest, headers),
          getContainedPolicies: (getContainedPoliciesRequest: GetContainedPoliciesRequest): Promise<GetContainedPoliciesResponse> =>
            httpClient.invoke('GET', '/query/v1/policies/contained', getContainedPoliciesRequest, headers),
          getCurrentSubjectPermissionsOnResource: (
            getCurrentSubjectPermissionsOnResourceRequest: GetCurrentSubjectPermissionsOnResourceRequest
          ): Promise<GetCurrentSubjectPermissionsOnResourceResponse> => httpClient.invoke('GET', '/v1/contextAssignments', getCurrentSubjectPermissionsOnResourceRequest, headers),
          getCurrentSubjectPermissionsOnResources: (
            getCurrentSubjectPermissionsOnResourcesRequest: GetCurrentSubjectPermissionsOnResourcesRequest
          ): Promise<GetCurrentSubjectPermissionsOnResourcesResponse> =>
            httpClient.invoke('GET', '/v1/contextsAssignments', getCurrentSubjectPermissionsOnResourcesRequest, headers),
          getPolicies: (queryGetPoliciesRequest: QueryGetPoliciesRequest): Promise<QueryGetPoliciesResponse> =>
            httpClient.invoke('GET', '/v1/policies', queryGetPoliciesRequest, headers),
          getPoliciesApplicableRestrictions: (
            getPoliciesApplicableRestrictionsRequest: GetPoliciesApplicableRestrictionsRequest
          ): Promise<GetPoliciesApplicableRestrictionsResponse> => httpClient.invoke('GET', '/query/v1/policies/restrictions', getPoliciesApplicableRestrictionsRequest, headers),
          getPoliciesAssignedOnResource: (getPoliciesAssignedOnResourceRequest: GetPoliciesAssignedOnResourceRequest): Promise<GetPoliciesAssignedOnResourceResponse> =>
            httpClient.invoke('GET', '/v1/resourceAssignments', getPoliciesAssignedOnResourceRequest, headers),
          getPoliciesPermissions: (getPoliciesPermissionsRequest: GetPoliciesPermissionsRequest): Promise<GetPoliciesPermissionsResponse> =>
            httpClient.invoke('GET', '/query/v1/policies/permissions', getPoliciesPermissionsRequest, headers),
          getPolicy: (queryGetPolicyRequest: QueryGetPolicyRequest): Promise<QueryGetPolicyResponse> =>
            httpClient.invoke('GET', '/query/v1/policy/{policy_id}', queryGetPolicyRequest, headers),
          getSubjectPoliciesOnCurrentAccount: (
            getSubjectPoliciesOnCurrentAccountRequest: GetSubjectPoliciesOnCurrentAccountRequest
          ): Promise<GetSubjectPoliciesOnCurrentAccountResponse> => httpClient.invoke('GET', '/v1/subjectAssignments', getSubjectPoliciesOnCurrentAccountRequest, headers),
        };
        (service as any).bulkIsPolicyAssigned.__http_method = 'GET';
        (service as any).bulkIsPolicyAssigned.__http_url = '/query/v1/policies/assigned';
        (service as any).filterPolicies.__http_method = 'GET';
        (service as any).filterPolicies.__http_url = '/query/v1/policies/filter';
        (service as any).getAssignments.__http_method = 'GET';
        (service as any).getAssignments.__http_url = '/v1/assignments/{assignment_ids}';
        (service as any).getContainedPolicies.__http_method = 'GET';
        (service as any).getContainedPolicies.__http_url = '/query/v1/policies/contained';
        (service as any).getCurrentSubjectPermissionsOnResource.__http_method = 'GET';
        (service as any).getCurrentSubjectPermissionsOnResource.__http_url = '/v1/contextAssignments';
        (service as any).getCurrentSubjectPermissionsOnResources.__http_method = 'GET';
        (service as any).getCurrentSubjectPermissionsOnResources.__http_url = '/v1/contextsAssignments';
        (service as any).getPolicies.__http_method = 'GET';
        (service as any).getPolicies.__http_url = '/v1/policies';
        (service as any).getPoliciesApplicableRestrictions.__http_method = 'GET';
        (service as any).getPoliciesApplicableRestrictions.__http_url = '/query/v1/policies/restrictions';
        (service as any).getPoliciesAssignedOnResource.__http_method = 'GET';
        (service as any).getPoliciesAssignedOnResource.__http_url = '/v1/resourceAssignments';
        (service as any).getPoliciesPermissions.__http_method = 'GET';
        (service as any).getPoliciesPermissions.__http_url = '/query/v1/policies/permissions';
        (service as any).getPolicy.__http_method = 'GET';
        (service as any).getPolicy.__http_url = '/query/v1/policy/{policy_id}';
        (service as any).getSubjectPoliciesOnCurrentAccount.__http_method = 'GET';
        (service as any).getSubjectPoliciesOnCurrentAccount.__http_url = '/v1/subjectAssignments';
        return service;
      };
    },
    AccountPoliciesManagement: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          assignPoliciesToTeamMember: (assignPoliciesToTeamMemberRequest: AssignPoliciesToTeamMemberRequest): Promise<AssignPoliciesToTeamMemberResponse> =>
            httpClient.invoke('POST', '/v1/users/{user_id}/policies', assignPoliciesToTeamMemberRequest, headers),
          bulkOverrideSubjectPolicies: (bulkOverrideSubjectPoliciesRequest: BulkOverrideSubjectPoliciesRequest): Promise<BulkOverrideSubjectPoliciesResponse> =>
            httpClient.invoke('POST', '/v1/bulk/subjects/policies/override', bulkOverrideSubjectPoliciesRequest, headers),
          clearTeamMemberPolicies: (clearTeamMemberPoliciesRequest: ClearTeamMemberPoliciesRequest): Promise<ClearTeamMemberPoliciesResponse> =>
            httpClient.invoke('DELETE', '/v1/users/{user_id}/policies', clearTeamMemberPoliciesRequest, headers),
          createPolicy: (createPolicyRequest: CreatePolicyRequest): Promise<CreatePolicyResponse> => httpClient.invoke('POST', '/v1/policies', createPolicyRequest, headers),
          deletePolicy: (deletePolicyRequest: DeletePolicyRequest): Promise<DeletePolicyResponse> =>
            httpClient.invoke('DELETE', '/v1/policies/{policy_id}', deletePolicyRequest, headers),
          deleteTeamMemberAssignments: (deleteTeamMemberAssignmentsRequest: DeleteTeamMemberAssignmentsRequest): Promise<DeleteTeamMemberAssignmentsResponse> =>
            httpClient.invoke('DELETE', '/v1/users/assignments', deleteTeamMemberAssignmentsRequest, headers),
          replaceAllTeamMemberPolicies: (replaceAllTeamMemberPoliciesRequest: ReplaceAllTeamMemberPoliciesRequest): Promise<ReplaceAllTeamMemberPoliciesResponse> =>
            httpClient.invoke('PUT', '/v1/users/{user_id}/policies', replaceAllTeamMemberPoliciesRequest, headers),
          replaceTeamMemberPolicies: (replaceTeamMemberPoliciesRequest: ReplaceTeamMemberPoliciesRequest): Promise<ReplaceTeamMemberPoliciesResponse> =>
            httpClient.invoke('PUT', '/v1/users/{user_id}/replace/policies', replaceTeamMemberPoliciesRequest, headers),
          updatePolicyAuthorizationData: (updatePolicyAuthorizationDataRequest: UpdatePolicyAuthorizationDataRequest): Promise<UpdatePolicyResponse> =>
            httpClient.invoke('PUT', '/v1/policies/{policy_id}/authorization-data', updatePolicyAuthorizationDataRequest, headers),
          updatePolicyMetadata: (updatePolicyMetadataRequest: UpdatePolicyMetadataRequest): Promise<UpdatePolicyResponse> =>
            httpClient.invoke('PATCH', '/v1/policies/{policy_id}/metadata', updatePolicyMetadataRequest, headers),
        };
        (service as any).assignPoliciesToTeamMember.__http_method = 'POST';
        (service as any).assignPoliciesToTeamMember.__http_url = '/v1/users/{user_id}/policies';
        (service as any).bulkOverrideSubjectPolicies.__http_method = 'POST';
        (service as any).bulkOverrideSubjectPolicies.__http_url = '/v1/bulk/subjects/policies/override';
        (service as any).clearTeamMemberPolicies.__http_method = 'DELETE';
        (service as any).clearTeamMemberPolicies.__http_url = '/v1/users/{user_id}/policies';
        (service as any).createPolicy.__http_method = 'POST';
        (service as any).createPolicy.__http_url = '/v1/policies';
        (service as any).deletePolicy.__http_method = 'DELETE';
        (service as any).deletePolicy.__http_url = '/v1/policies/{policy_id}';
        (service as any).deleteTeamMemberAssignments.__http_method = 'DELETE';
        (service as any).deleteTeamMemberAssignments.__http_url = '/v1/users/assignments';
        (service as any).replaceAllTeamMemberPolicies.__http_method = 'PUT';
        (service as any).replaceAllTeamMemberPolicies.__http_url = '/v1/users/{user_id}/policies';
        (service as any).replaceTeamMemberPolicies.__http_method = 'PUT';
        (service as any).replaceTeamMemberPolicies.__http_url = '/v1/users/{user_id}/replace/policies';
        (service as any).updatePolicyAuthorizationData.__http_method = 'PUT';
        (service as any).updatePolicyAuthorizationData.__http_url = '/v1/policies/{policy_id}/authorization-data';
        (service as any).updatePolicyMetadata.__http_method = 'PATCH';
        (service as any).updatePolicyMetadata.__http_url = '/v1/policies/{policy_id}/metadata';
        return service;
      };
    },
    AppPoliciesManagementService: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          clearAssignedAppPolicies: (clearAssignedAppPoliciesRequest: ClearAssignedAppPoliciesRequest): Promise<ClearAssignedAppPoliciesResponse> =>
            httpClient.invoke('DELETE', '/v1/app/{app_id}/account/{account_id}/assigned-policies', clearAssignedAppPoliciesRequest, headers),
        };
        (service as any).clearAssignedAppPolicies.__http_method = 'DELETE';
        (service as any).clearAssignedAppPolicies.__http_url = '/v1/app/{app_id}/account/{account_id}/assigned-policies';
        return service;
      };
    },
    BackOfficeAuthorizationService: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          bulkIsPermitted: (bulkBackOfficeIsPermittedRequest: BulkBackOfficeIsPermittedRequest): Promise<BulkIsPermittedResponse> =>
            httpClient.invoke('GET', '/v1/authorization/bo/bulk_is_permitted', bulkBackOfficeIsPermittedRequest, headers),
          isPermittedByAppInstance: (isPermittedByAppInstanceRequest: IsPermittedByAppInstanceRequest): Promise<IsPermittedResponse> =>
            httpClient.invoke('GET', '/v1/authorization/bo/is_permitted_by_app_instance', isPermittedByAppInstanceRequest, headers),
        };
        (service as any).bulkIsPermitted.__http_method = 'GET';
        (service as any).bulkIsPermitted.__http_url = '/v1/authorization/bo/bulk_is_permitted';
        (service as any).isPermittedByAppInstance.__http_method = 'GET';
        (service as any).isPermittedByAppInstance.__http_url = '/v1/authorization/bo/is_permitted_by_app_instance';
        return service;
      };
    },
    SitePoliciesManagement: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          assignPolicies: (assignPoliciesRequest: AssignPoliciesRequest): Promise<AssignPoliciesResponse> =>
            httpClient.invoke('PUT', '/v1/account/{account_id}/policies', assignPoliciesRequest, headers),
          clearAssignedPolicies: (clearAssignedPoliciesRequest: ClearAssignedPoliciesRequest): Promise<ClearAssignedPoliciesResponse> =>
            httpClient.invoke('DELETE', '/v1/account/{account_id}/assigned-policies', clearAssignedPoliciesRequest, headers),
          replaceAllAssignedPolicies: (replaceAllAssignedPoliciesRequest: ReplaceAllAssignedPoliciesRequest): Promise<ReplaceAllAssignedPoliciesResponse> =>
            httpClient.invoke('PUT', '/v1/account/{account_id}/assigned-policies', replaceAllAssignedPoliciesRequest, headers),
          replaceAllAssignedPoliciesCondition: (
            replaceAllAssignedPoliciesConditionRequest: ReplaceAllAssignedPoliciesConditionRequest
          ): Promise<ReplaceAllAssignedPoliciesConditionResponse> =>
            httpClient.invoke('PUT', '/v1/account/{account_id}/assigned-policies-condition', replaceAllAssignedPoliciesConditionRequest, headers),
          updatePoliciesOnSiteTransfer: (updatePoliciesOnSiteTransferRequest: UpdatePoliciesOnSiteTransferRequest): Promise<UpdatePoliciesOnSiteTransferResponse> =>
            httpClient.invoke('PUT', '/v1/site-transfer', updatePoliciesOnSiteTransferRequest, headers),
        };
        (service as any).assignPolicies.__http_method = 'PUT';
        (service as any).assignPolicies.__http_url = '/v1/account/{account_id}/policies';
        (service as any).clearAssignedPolicies.__http_method = 'DELETE';
        (service as any).clearAssignedPolicies.__http_url = '/v1/account/{account_id}/assigned-policies';
        (service as any).replaceAllAssignedPolicies.__http_method = 'PUT';
        (service as any).replaceAllAssignedPolicies.__http_url = '/v1/account/{account_id}/assigned-policies';
        (service as any).replaceAllAssignedPoliciesCondition.__http_method = 'PUT';
        (service as any).replaceAllAssignedPoliciesCondition.__http_url = '/v1/account/{account_id}/assigned-policies-condition';
        (service as any).updatePoliciesOnSiteTransfer.__http_method = 'PUT';
        (service as any).updatePoliciesOnSiteTransfer.__http_url = '/v1/site-transfer';
        return service;
      };
    },
    SubjectsQueryService: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          getCurrentSubjectContainedPolicies: (
            getCurrentSubjectContainedPoliciesRequest: GetCurrentSubjectContainedPoliciesRequest
          ): Promise<GetCurrentSubjectContainedPoliciesResponse> =>
            httpClient.invoke('GET', '/v1/query/subject/contained/policies', getCurrentSubjectContainedPoliciesRequest, headers),
          getSubjectAssignedPolicies: (getSubjectAssignedPoliciesRequest: GetSubjectAssignedPoliciesRequest): Promise<GetSubjectAssignedPoliciesResponse> =>
            httpClient.invoke('GET', '/v1/query/subject/{subject.id}/assignedPolicies', getSubjectAssignedPoliciesRequest, headers),
          getSubjectPermittedResources: (getSubjectPermittedResourcesRequest: GetSubjectPermittedResourcesRequest): Promise<GetSubjectPermittedResourcesResponse> =>
            httpClient.invoke('GET', '/v1/query/subjects/permitted_resources/{action}', getSubjectPermittedResourcesRequest, headers),
          getSubjectRoles: (getSubjectRolesRequest: GetSubjectRolesRequest): Promise<GetSubjectRolesResponse> =>
            httpClient.invoke('GET', '/v1/query/subject/roles', getSubjectRolesRequest, headers),
        };
        (service as any).getCurrentSubjectContainedPolicies.__http_method = 'GET';
        (service as any).getCurrentSubjectContainedPolicies.__http_url = '/v1/query/subject/contained/policies';
        (service as any).getSubjectAssignedPolicies.__http_method = 'GET';
        (service as any).getSubjectAssignedPolicies.__http_url = '/v1/query/subject/{subject.id}/assignedPolicies';
        (service as any).getSubjectPermittedResources.__http_method = 'GET';
        (service as any).getSubjectPermittedResources.__http_url = '/v1/query/subjects/permitted_resources/{action}';
        (service as any).getSubjectRoles.__http_method = 'GET';
        (service as any).getSubjectRoles.__http_url = '/v1/query/subject/roles';
        return service;
      };
    },
    UsersAuthorizationQueryService: () => {
      return (headers?: { [headerName: string]: any }) => {
        const service = {
          bulkGetPermittedSubjectsCount: (bulkGetPermittedSubjectsCountRequest: BulkGetPermittedSubjectsCountRequest): Promise<BulkGetPermittedSubjectsCountResponse> =>
            httpClient.invoke('POST', '/v2/query/permitted_subjects_count', bulkGetPermittedSubjectsCountRequest, headers),
          getPermittedSubjectsRoles: (getPermittedSubjectsRolesRequest: GetPermittedSubjectsRolesRequest): Promise<GetPermittedSubjectsRolesResponse> =>
            httpClient.invoke('GET', '/v2/query/resourceAssignments', getPermittedSubjectsRolesRequest, headers),
          getPermittedSubjectsStatements: (getPermittedSubjectsStatementsRequest: GetPermittedSubjectsStatementsRequest): Promise<GetPermittedSubjectsStatementsResponse> =>
            httpClient.invoke('POST', '/v1/assignments/users/query', getPermittedSubjectsStatementsRequest, headers),
        };
        (service as any).bulkGetPermittedSubjectsCount.__http_method = 'POST';
        (service as any).bulkGetPermittedSubjectsCount.__http_url = '/v2/query/permitted_subjects_count';
        (service as any).getPermittedSubjectsRoles.__http_method = 'GET';
        (service as any).getPermittedSubjectsRoles.__http_url = '/v2/query/resourceAssignments';
        (service as any).getPermittedSubjectsStatements.__http_method = 'POST';
        (service as any).getPermittedSubjectsStatements.__http_url = '/v1/assignments/users/query';
        return service;
      };
    },
  };
};

(AuthorizationServer as any).__transport = 'http';

export * from './types';
