"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.createQueryOperations = createQueryOperations;
const query_builder_1 = require("../query-builder");
const input_types_1 = require("../input-types");
function createQueryOperations(client) {
    return {
        currentUserId: (options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'CurrentUserId',
            fieldName: 'currentUserId',
            ...(0, query_builder_1.buildCustomDocument)('query', 'CurrentUserId', 'currentUserId', options?.select, undefined, [], input_types_1.connectionFieldsMap, undefined),
        }),
        currentUserAgent: (options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'CurrentUserAgent',
            fieldName: 'currentUserAgent',
            ...(0, query_builder_1.buildCustomDocument)('query', 'CurrentUserAgent', 'currentUserAgent', options?.select, undefined, [], input_types_1.connectionFieldsMap, undefined),
        }),
        currentIpAddress: (options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'CurrentIpAddress',
            fieldName: 'currentIpAddress',
            ...(0, query_builder_1.buildCustomDocument)('query', 'CurrentIpAddress', 'currentIpAddress', options?.select, undefined, [], input_types_1.connectionFieldsMap, undefined),
        }),
        requireStepUp: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'RequireStepUp',
            fieldName: 'requireStepUp',
            ...(0, query_builder_1.buildCustomDocument)('query', 'RequireStepUp', 'requireStepUp', options?.select, args, [
                {
                    name: 'stepUpType',
                    type: 'String',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        appPermissionsGetPaddedMask: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'AppPermissionsGetPaddedMask',
            fieldName: 'appPermissionsGetPaddedMask',
            ...(0, query_builder_1.buildCustomDocument)('query', 'AppPermissionsGetPaddedMask', 'appPermissionsGetPaddedMask', options?.select, args, [
                {
                    name: 'mask',
                    type: 'BitString',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        orgPermissionsGetPaddedMask: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'OrgPermissionsGetPaddedMask',
            fieldName: 'orgPermissionsGetPaddedMask',
            ...(0, query_builder_1.buildCustomDocument)('query', 'OrgPermissionsGetPaddedMask', 'orgPermissionsGetPaddedMask', options?.select, args, [
                {
                    name: 'mask',
                    type: 'BitString',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        stepsAchieved: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'StepsAchieved',
            fieldName: 'stepsAchieved',
            ...(0, query_builder_1.buildCustomDocument)('query', 'StepsAchieved', 'stepsAchieved', options?.select, args, [
                {
                    name: 'level',
                    type: 'String',
                },
                {
                    name: 'roleId',
                    type: 'UUID',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        revParse: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'RevParse',
            fieldName: 'revParse',
            ...(0, query_builder_1.buildCustomDocument)('query', 'RevParse', 'revParse', options?.select, args, [
                {
                    name: 'dbId',
                    type: 'UUID',
                },
                {
                    name: 'storeId',
                    type: 'UUID',
                },
                {
                    name: 'refname',
                    type: 'String',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        resolveBlueprintField: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'ResolveBlueprintField',
            fieldName: 'resolveBlueprintField',
            ...(0, query_builder_1.buildCustomDocument)('query', 'ResolveBlueprintField', 'resolveBlueprintField', options?.select, args, [
                {
                    name: 'databaseId',
                    type: 'UUID',
                },
                {
                    name: 'tableId',
                    type: 'UUID',
                },
                {
                    name: 'fieldName',
                    type: 'String',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        orgIsManagerOf: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'OrgIsManagerOf',
            fieldName: 'orgIsManagerOf',
            ...(0, query_builder_1.buildCustomDocument)('query', 'OrgIsManagerOf', 'orgIsManagerOf', options?.select, args, [
                {
                    name: 'pEntityId',
                    type: 'UUID',
                },
                {
                    name: 'pManagerId',
                    type: 'UUID',
                },
                {
                    name: 'pUserId',
                    type: 'UUID',
                },
                {
                    name: 'pMaxDepth',
                    type: 'Int',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        appPermissionsGetMask: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'AppPermissionsGetMask',
            fieldName: 'appPermissionsGetMask',
            ...(0, query_builder_1.buildCustomDocument)('query', 'AppPermissionsGetMask', 'appPermissionsGetMask', options?.select, args, [
                {
                    name: 'ids',
                    type: '[UUID]',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        orgPermissionsGetMask: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'OrgPermissionsGetMask',
            fieldName: 'orgPermissionsGetMask',
            ...(0, query_builder_1.buildCustomDocument)('query', 'OrgPermissionsGetMask', 'orgPermissionsGetMask', options?.select, args, [
                {
                    name: 'ids',
                    type: '[UUID]',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        resolveBlueprintTable: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'ResolveBlueprintTable',
            fieldName: 'resolveBlueprintTable',
            ...(0, query_builder_1.buildCustomDocument)('query', 'ResolveBlueprintTable', 'resolveBlueprintTable', options?.select, args, [
                {
                    name: 'databaseId',
                    type: 'UUID',
                },
                {
                    name: 'tableName',
                    type: 'String',
                },
                {
                    name: 'schemaName',
                    type: 'String',
                },
                {
                    name: 'tableMap',
                    type: 'JSON',
                },
                {
                    name: 'defaultSchemaId',
                    type: 'UUID',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        appPermissionsGetMaskByNames: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'AppPermissionsGetMaskByNames',
            fieldName: 'appPermissionsGetMaskByNames',
            ...(0, query_builder_1.buildCustomDocument)('query', 'AppPermissionsGetMaskByNames', 'appPermissionsGetMaskByNames', options?.select, args, [
                {
                    name: 'names',
                    type: '[String]',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        orgPermissionsGetMaskByNames: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'OrgPermissionsGetMaskByNames',
            fieldName: 'orgPermissionsGetMaskByNames',
            ...(0, query_builder_1.buildCustomDocument)('query', 'OrgPermissionsGetMaskByNames', 'orgPermissionsGetMaskByNames', options?.select, args, [
                {
                    name: 'names',
                    type: '[String]',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        appPermissionsGetByMask: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'AppPermissionsGetByMask',
            fieldName: 'appPermissionsGetByMask',
            ...(0, query_builder_1.buildCustomDocument)('query', 'AppPermissionsGetByMask', 'appPermissionsGetByMask', options?.select, args, [
                {
                    name: 'mask',
                    type: 'BitString',
                },
                {
                    name: 'first',
                    type: 'Int',
                },
                {
                    name: 'offset',
                    type: 'Int',
                },
                {
                    name: 'after',
                    type: 'Cursor',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        orgPermissionsGetByMask: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'OrgPermissionsGetByMask',
            fieldName: 'orgPermissionsGetByMask',
            ...(0, query_builder_1.buildCustomDocument)('query', 'OrgPermissionsGetByMask', 'orgPermissionsGetByMask', options?.select, args, [
                {
                    name: 'mask',
                    type: 'BitString',
                },
                {
                    name: 'first',
                    type: 'Int',
                },
                {
                    name: 'offset',
                    type: 'Int',
                },
                {
                    name: 'after',
                    type: 'Cursor',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        getAllObjectsFromRoot: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'GetAllObjectsFromRoot',
            fieldName: 'getAllObjectsFromRoot',
            ...(0, query_builder_1.buildCustomDocument)('query', 'GetAllObjectsFromRoot', 'getAllObjectsFromRoot', options?.select, args, [
                {
                    name: 'databaseId',
                    type: 'UUID',
                },
                {
                    name: 'id',
                    type: 'UUID',
                },
                {
                    name: 'first',
                    type: 'Int',
                },
                {
                    name: 'offset',
                    type: 'Int',
                },
                {
                    name: 'after',
                    type: 'Cursor',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        getPathObjectsFromRoot: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'GetPathObjectsFromRoot',
            fieldName: 'getPathObjectsFromRoot',
            ...(0, query_builder_1.buildCustomDocument)('query', 'GetPathObjectsFromRoot', 'getPathObjectsFromRoot', options?.select, args, [
                {
                    name: 'databaseId',
                    type: 'UUID',
                },
                {
                    name: 'id',
                    type: 'UUID',
                },
                {
                    name: 'path',
                    type: '[String]',
                },
                {
                    name: 'first',
                    type: 'Int',
                },
                {
                    name: 'offset',
                    type: 'Int',
                },
                {
                    name: 'after',
                    type: 'Cursor',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        getObjectAtPath: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'GetObjectAtPath',
            fieldName: 'getObjectAtPath',
            ...(0, query_builder_1.buildCustomDocument)('query', 'GetObjectAtPath', 'getObjectAtPath', options.select, args, [
                {
                    name: 'dbId',
                    type: 'UUID',
                },
                {
                    name: 'storeId',
                    type: 'UUID',
                },
                {
                    name: 'path',
                    type: '[String]',
                },
                {
                    name: 'refname',
                    type: 'String',
                },
            ], input_types_1.connectionFieldsMap, 'Object'),
        }),
        stepsRequired: (args, options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'StepsRequired',
            fieldName: 'stepsRequired',
            ...(0, query_builder_1.buildCustomDocument)('query', 'StepsRequired', 'stepsRequired', options?.select, args, [
                {
                    name: 'level',
                    type: 'String',
                },
                {
                    name: 'roleId',
                    type: 'UUID',
                },
                {
                    name: 'first',
                    type: 'Int',
                },
                {
                    name: 'offset',
                    type: 'Int',
                },
                {
                    name: 'after',
                    type: 'Cursor',
                },
            ], input_types_1.connectionFieldsMap, undefined),
        }),
        currentUser: (options) => new query_builder_1.QueryBuilder({
            client,
            operation: 'query',
            operationName: 'CurrentUser',
            fieldName: 'currentUser',
            ...(0, query_builder_1.buildCustomDocument)('query', 'CurrentUser', 'currentUser', options.select, undefined, [], input_types_1.connectionFieldsMap, 'User'),
        }),
    };
}
