openapi: 3.0.0
info:
    title: 'AURA API'
    contact:
        email: pomoc@questy.pl
    version: '2.0'
paths:
    /api:
        get:
            description: 'Get homepage, check if API works'
            operationId: getHome
            responses:
                200:
                    description: Success
                401:
                    description: 'Access denied'
    /api/me:
        get:
            description: 'Get user info'
            operationId: getMe
            responses:
                200:
                    description: Success
                401:
                    description: 'Access denied'
    /api/files/upload:
        post:
            description: 'Upload file/ files. You should send the file (or files) in the *data_files* parameter, e.g. as *form-data*'
            operationId: postDataFile
            requestBody:
                $ref: '#/components/requestBodies/RequestBodyFilePost'
            responses:
                201:
                    description: Created
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
    /api/files/upload/urls:
        post:
            description: 'Upload file/ files from URL. You should send the URL (or URLs) in the *data_files_urls* parameter'
            operationId: postDataFileFromUrls
            requestBody:
                $ref: '#/components/requestBodies/RequestBodyFileUrlPost'
            responses:
                201:
                    description: Created
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
    /api/merged_modules:
        get:
            description: 'Get data collection from merged modules'
            operationId: getDataCollectionBasicModules
            parameters:
                -
                    $ref: '#/components/parameters/modules'
                -
                    $ref: '#/components/parameters/modules_params'
            responses:
                200:
                    description: Success
    /api/merged_modules/autoselect:
        get:
            description: 'Get data collection from merged modules for autoselect'
            operationId: getDataCollectionBasicModulesAutoselect
            parameters:
                -
                    $ref: '#/components/parameters/modules'
                -
                    $ref: '#/components/parameters/modules_params'
            responses:
                200:
                    description: Success
    '/api/{contextModule}/{contextId}/{module}':
        get:
            description: 'Get data item for context, for example: commissionHistory for commission - commissions/1/commission_histories'
            operationId: getDataItemForContext
            parameters:
                -
                    $ref: '#/components/parameters/contextModule'
                -
                    $ref: '#/components/parameters/contextId'
                -
                    $ref: '#/components/parameters/module'
                -
                    $ref: '#/components/parameters/setting_with_relations'
                -
                    $ref: '#/components/parameters/setting_lang'
                -
                    $ref: '#/components/parameters/setting_with_editable_settings_for_action'
                -
                    $ref: '#/components/parameters/fields'
                -
                    $ref: '#/components/parameters/extra_fields'
                -
                    $ref: '#/components/parameters/filter'
                -
                    $ref: '#/components/parameters/filterOr'
                -
                    $ref: '#/components/parameters/filterAnd'
            responses:
                200:
                    description: Success
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint/ item does not exist'
    /api/targets/meta:
        get:
            description: '**Credential levels for modules:**<br />0: none<br />1: show<br />2: edit<br />3: create<br />4: delete<br /><br />**Credential levels for fields and extra_fields:**<br />0: none<br />1: show<br />2: edit<br />'
            operationId: getMetaTarget
            parameters:
                -
                    $ref: '#/components/parameters/for_fieldName'
                -
                    $ref: '#/components/parameters/setting_with_editable_settings_for_action'
                -
                    $ref: '#/components/parameters/TargetGETFields'
                -
                    $ref: '#/components/parameters/TargetGETExtra_fields'
            responses:
                200:
                    description: Success
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint/ item does not exist'
            tags:
                - Target
    '/api/targets/{id}':
        get:
            description: 'Get data item'
            operationId: getTarget
            parameters:
                -
                    $ref: '#/components/parameters/id'
                -
                    $ref: '#/components/parameters/setting_with_relations'
                -
                    $ref: '#/components/parameters/setting_lang'
                -
                    $ref: '#/components/parameters/setting_with_editable_settings_for_action'
                -
                    $ref: '#/components/parameters/setting_email_messages_mark_seen'
                -
                    $ref: '#/components/parameters/setting_email_messages_save_in_db'
                -
                    $ref: '#/components/parameters/setting_email_messages_check_in_db'
                -
                    $ref: '#/components/parameters/setting_with_cache'
                -
                    $ref: '#/components/parameters/setting_limit_to_my_settings'
                -
                    $ref: '#/components/parameters/TargetGETFields'
                -
                    $ref: '#/components/parameters/TargetGETExtra_fields'
                -
                    $ref: '#/components/parameters/filter'
                -
                    $ref: '#/components/parameters/filterOr'
                -
                    $ref: '#/components/parameters/filterAnd'
            responses:
                200:
                    description: Success
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint/ item does not exist'
            tags:
                - Target
        delete:
            description: 'Delete data item'
            operationId: deleteTarget
            parameters:
                -
                    $ref: '#/components/parameters/id'
                -
                    $ref: '#/components/parameters/setting_with_editable_settings_for_action'
                -
                    $ref: '#/components/parameters/setting_limit_to_my_settings'
                -
                    $ref: '#/components/parameters/filter'
                -
                    $ref: '#/components/parameters/filterOr'
                -
                    $ref: '#/components/parameters/filterAnd'
            responses:
                200:
                    description: Success
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint/ item does not exist'
            tags:
                - Target
        patch:
            description: 'Patch data item'
            operationId: patchTarget
            parameters:
                -
                    $ref: '#/components/parameters/id'
            requestBody:
                $ref: '#/components/requestBodies/TargetPATCHRequestBody'
            responses:
                200:
                    description: Success
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint does not exist'
            tags:
                - Target
    /api/targets:
        get:
            description: 'Get data collection<br />**Example:** <br />Get account companies with relations, where primary relationship manager = 2, name contains ''e'' or ''E'' and ID is greater than 20. Returned fields are limited to id and name. Extra fields are: address and primary relationship manager''s full name. Results are order by company''s name.<br />**Query:** /api/account_companies?setting[with_relations]=1&filter[ph.id]=2&filter[name][hasText]=e&filter[id][gt]=20&extra_fields=address,ph.fullName&fields=name&order[name]=asc'
            operationId: getTargets
            parameters:
                -
                    $ref: '#/components/parameters/setting_with_relations'
                -
                    $ref: '#/components/parameters/setting_with_editable_settings_for_action'
                -
                    $ref: '#/components/parameters/setting_email_messages_mark_seen'
                -
                    $ref: '#/components/parameters/setting_email_messages_save_in_db'
                -
                    $ref: '#/components/parameters/setting_email_messages_check_in_db'
                -
                    $ref: '#/components/parameters/setting_with_cache'
                -
                    $ref: '#/components/parameters/setting_limit_to_my_settings'
                -
                    $ref: '#/components/parameters/TargetGETFieldsForCollection'
                -
                    $ref: '#/components/parameters/TargetGETExtra_fieldsForCollection'
                -
                    $ref: '#/components/parameters/order'
                -
                    $ref: '#/components/parameters/filter'
                -
                    $ref: '#/components/parameters/filterOr'
                -
                    $ref: '#/components/parameters/filterAnd'
                -
                    $ref: '#/components/parameters/setting_lang'
                -
                    $ref: '#/components/parameters/page_limit'
                -
                    $ref: '#/components/parameters/page_offset'
                -
                    $ref: '#/components/parameters/page_number'
            responses:
                200:
                    description: Success
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint does not exist'
            tags:
                - Target
        post:
            description: 'Post data item/ collection'
            operationId: postTargets
            requestBody:
                $ref: '#/components/requestBodies/TargetPOSTForCollectionRequestBody'
            responses:
                201:
                    description: Created
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint does not exist'
            tags:
                - Target
        delete:
            description: 'Delete data collection'
            operationId: deleteTargets
            parameters:
                -
                    $ref: '#/components/parameters/setting_with_editable_settings_for_action'
                -
                    $ref: '#/components/parameters/setting_limit_to_my_settings'
                -
                    name: filter
                    in: query
                    description: 'Data filtering. Filter types: <ul><li>eq - equal, you can ignore this parameter in query,</li><li>neq - different from</li><li>lt - less than</li><li>lte - smaller, equal to from</li><li>gt - exceed from</li><li>gte - much, equal from</li><li>isNull - is empty (you cannot enter a filter value)</li><li>isNotNull - is non-empty (do not specify filter value)</li><li>in - belongs to (filter value should be an array)</li><li>notIn - does not belong to (filter value should be an array)</li><li>like - equal word expressed (you can use a query with e.g.%, remember only about proper URL formatting)</li><li>ilike - LIKE, which is case insensitive (UPPER function)</li><li>notLike - uneven word expressed (you can use here a query with e.g.%, you should only remember about proper URL formatting)</li><li>hasText - (like ilike), %% is added to search</li></ul>**Query example:** filter[accountUsers.id][isNotNull]&filter[name][ilike]=guest&filter[id]=88550'
                    required: true
                    style: deepObject
                    schema:
                        type: object
                        items:
                            type: object
                -
                    $ref: '#/components/parameters/filterOr'
                -
                    $ref: '#/components/parameters/filterAnd'
            responses:
                200:
                    description: Success
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint does not exist'
            tags:
                - Target
        patch:
            description: 'Patch data collection'
            operationId: patchTargets
            requestBody:
                $ref: '#/components/requestBodies/TargetPATCHForCollectionRequestBody'
            responses:
                200:
                    description: Success
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint does not exist'
            tags:
                - Target
    /api/targets/execute:
        get:
            description: 'Get data collection for execute, for example: get SQL results from odbcReports - /odbc_reports/execute'
            operationId: getForExecuteTargets
            parameters:
                -
                    $ref: '#/components/parameters/setting_with_relations'
                -
                    $ref: '#/components/parameters/setting_lang'
                -
                    $ref: '#/components/parameters/setting_with_editable_settings_for_action'
                -
                    $ref: '#/components/parameters/order'
                -
                    $ref: '#/components/parameters/filter'
                -
                    $ref: '#/components/parameters/filterOr'
                -
                    $ref: '#/components/parameters/filterAnd'
                -
                    $ref: '#/components/parameters/page_limit'
                -
                    $ref: '#/components/parameters/page_offset'
                -
                    $ref: '#/components/parameters/page_number'
            responses:
                200:
                    description: Success
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint does not exist'
            tags:
                - Target
    /api/targets/autoselect:
        get:
            description: 'Get data collection for autoselect, in this mode the module''s credentials are not checked.'
            operationId: getAutoselectTargets
            parameters:
                -
                    $ref: '#/components/parameters/setting_with_relations'
                -
                    $ref: '#/components/parameters/setting_lang'
                -
                    $ref: '#/components/parameters/setting_with_editable_settings_for_action'
                -
                    $ref: '#/components/parameters/TargetGETFieldsForCollection'
                -
                    $ref: '#/components/parameters/TargetGETExtra_fieldsForCollection'
                -
                    $ref: '#/components/parameters/order'
                -
                    $ref: '#/components/parameters/filter'
                -
                    $ref: '#/components/parameters/filterOr'
                -
                    $ref: '#/components/parameters/filterAnd'
                -
                    $ref: '#/components/parameters/page_limit'
                -
                    $ref: '#/components/parameters/page_offset'
                -
                    $ref: '#/components/parameters/page_number'
            responses:
                200:
                    description: Success
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint does not exist'
            tags:
                - Target
    '/api/targets/{id}/generate/pdf':
        post:
            description: 'Generate data item pdf'
            operationId: generatePdfTarget
            parameters:
                -
                    $ref: '#/components/parameters/id'
            requestBody:
                $ref: '#/components/requestBodies/RequestGeneratePdf'
            responses:
                201:
                    description: Created
                400:
                    description: 'Bad request'
                401:
                    description: 'Access denied'
                403:
                    description: Forbidden
                404:
                    description: 'Endpoint does not exist'
            tags:
                - Target
components:
    schemas:
        AccountCompanyAura:
            title: AccountCompanyAura
            description: 'AccountCompanyAura model'
            properties:
                value:
                    type: string
                    nullable: true
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
            type: object
        AccountUserAura:
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
            allOf:
                -
                    $ref: '#/components/schemas/PersonBuilder'
        CampaignOpportunityAura:
            title: CampaignOpportunityAura
            description: 'CampaignOpportunityAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        CommissionAura:
            title: CommissionAura
            description: 'CommissionAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        CommissionToCommissionAura:
            title: CommissionToCommissionAura
            description: 'CommissionToCommissionAura model'
            properties:
                id:
                    description: 'Commission ID'
                    type: integer
                    format: integer
                    example: 1
                    nullable: true
                subtype:
                    description: 'subtype <parent, child, parallelStart, parallelEnd>'
                    type: string
                    format: string
                    nullable: true
                delay:
                    description: delay
                    type: integer
                    format: integer
                    example: 1
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
            type: object
        CommunicationAura:
            title: CommunicationAura
            description: 'CommunicationAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        CommunicationSenderAura:
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
            allOf:
                -
                    $ref: '#/components/schemas/PersonBuilder'
        CommunicationThreadsAura:
            title: CommunicationThreadsAura
            description: 'CommunicationThreadsAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        DocumentInvoiceAura:
            title: DocumentInvoiceAura
            description: 'DocumentInvoiceAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        DocumentOfferQuestionAura:
            title: DocumentOfferQuestionAura
            description: 'DocumentOfferQuestionAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        DocumentOrderAura:
            title: DocumentOrderAura
            description: 'DocumentOrderAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        DocumentPaymentAura:
            title: DocumentPaymentAura
            description: 'DocumentPaymentAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        DocumentStoreAura:
            title: DocumentStoreAura
            description: 'DocumentStoreAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        EmailMessageAura:
            title: EmailMessageAura
            description: 'EmailMessageAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        EstimatedQuantityAura:
            title: EstimatedQuantityAura
            description: 'EstimatedQuantityAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        FileAura:
            title: FileAura
            description: 'FileAura model'
            properties:
                extension:
                    type: string
                    nullable: true
                md5:
                    type: string
                    nullable: true
                dbName:
                    type: string
                    nullable: true
                fileName:
                    type: string
                    nullable: true
                mimeType:
                    type: string
                    nullable: true
                fileSize:
                    type: integer
                    nullable: true
                dateCreate:
                    type: string
                    format: date-time
                    nullable: true
                isTmp:
                    type: boolean
                uris: {  }
                isAttachment:
                    type: boolean
                fileToken:
                    type: string
                    nullable: true
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
            type: object
        FileToProductAura:
            properties:
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
            allOf:
                -
                    $ref: '#/components/schemas/FileAura'
                -
                    title: FileToProductAura
                    description: 'FileToProductAura model'
                    properties:
                        id:
                            description: 'File ID'
                            type: integer
                            format: integer
                            example: 1
                            nullable: true
                        position:
                            description: position
                            type: integer
                            format: integer
                            example: 1
                            nullable: true
                    type: object
        OdbcReportAura:
            title: OdbcReportAura
            description: 'OdbcReportAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        ProductAura:
            title: ProductAura
            description: 'ProductAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        ProductCategoryAura:
            title: ProductCategoryAura
            description: 'ProductCategoryAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        ProductCompleteAura:
            properties:
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
            allOf:
                -
                    $ref: '#/components/schemas/ProductAura'
                -
                    title: ProductCompleteAura
                    description: 'ProductCompleteAura model'
                    properties:
                        id:
                            description: 'Product ID'
                            type: integer
                            format: integer
                            example: 1
                            nullable: true
                        quantity:
                            description: quantity
                            type: number
                            format: number
                            example: 1
                            nullable: true
                        priceNetto:
                            description: priceNetto
                            type: number
                            format: number
                            example: 1
                            nullable: true
                    type: object
        ServicedProductAura:
            title: ServicedProductAura
            description: 'ServicedProductAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        SettingAura:
            title: SettingAura
            description: 'SettingAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        TargetAura:
            title: TargetAura
            description: 'TargetAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        TargetObjectiveAura:
            title: TargetObjectiveAura
            description: 'TargetObjectiveAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        TaskAura:
            title: TaskAura
            description: 'TaskAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        TaskTypeAura:
            title: TaskTypeAura
            description: 'TaskTypeAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        TemplateAura:
            title: TemplateAura
            description: 'TemplateAura model'
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
        UserUserAura:
            properties:
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
            allOf:
                -
                    $ref: '#/components/schemas/PersonBuilder'
        PersonBuilder:
            title: PersonBuilder
            description: 'PersonBuilder model'
            properties:
                firstName:
                    type: string
                    nullable: true
                lastName:
                    type: string
                    nullable: true
                name:
                    type: string
                    nullable: true
                avatar:
                    type: string
                    nullable: true
                id:
                    type: integer
                    nullable: true
                type:
                    type: string
                    readOnly: true
                    nullable: true
                subtype:
                    type: string
                    nullable: true
            type: object
        ApiAttributeDM:
            title: 'Attribute model'
            description: 'Attribute model'
            properties:
                id:
                    description: 'attribute id'
                    type: integer
                    format: integer
                    example: 1
            type: object
        ApiAttributeListPositionDM:
            title: listPosition
            description: 'Attribute list position model'
            properties:
                id:
                    description: 'attribute id'
                    type: integer
                    format: integer
                    example: 1
                value:
                    type: string
                    format: string
                ordering:
                    type: integer
                    format: integer
            type: object
            format: object
        ApiAttributeListPositionValueDM:
            title: listPositionValue
            description: 'Attribute list position value model'
            properties:
                id:
                    description: 'attribute id'
                    type: integer
                    format: integer
                    example: 1
                value:
                    type: string
                    format: string
                selected:
                    type: boolean
                    format: boolean
                ordering:
                    type: integer
                    format: integer
            type: object
            format: object
        ApiAttributeOptionDM:
            title: 'Attribute option model'
            description: 'Attribute option model'
            properties:
                displayPriority:
                    type: integer
                    format: integer
                    nullable: true
                forPosition:
                    type: boolean
                    format: boolean
                registerEventOnchange:
                    type: boolean
                    format: boolean
                asHTML:
                    type: boolean
                    format: boolean
            type: object
        ApiAttributeShowDM:
            title: 'Attribute model'
            description: 'Attribute model'
            properties:
                id:
                    description: 'attribute id'
                    type: integer
                    format: integer
                    example: 1
                uuid:
                    description: 'property for system attributes'
                    type: string
                    format: uuid
                    nullable: true
                name:
                    type: string
                    format: string
                type:
                    type: string
                    format: string
                options:
                    $ref: '#/components/schemas/ApiAttributeOptionDM'
            type: object
        ApiAttributeTypeAccountUserEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: 'account user'
                    description: 'Attribute type account user model'
                    properties:
                        value:
                            title: account_users
                            description: 'integer or array'
                            format: object
                            nullable: true
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectIdDM'
                                -
                                    $ref: '#/components/schemas/ApiObjectIdsDM'
                    type: object
        ApiAttributeTypeBoolEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: bool
                    description: 'Attribute type bool model'
                    properties:
                        value:
                            type: boolean
                            format: bool
                    type: object
        ApiAttributeTypeCompanyEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: company
                    description: 'Attribute type company model'
                    properties:
                        value:
                            title: companies
                            description: 'integer or array'
                            format: object
                            nullable: true
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectIdDM'
                                -
                                    $ref: '#/components/schemas/ApiObjectIdsDM'
                    type: object
        ApiAttributeTypeDateEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: date
                    description: 'Attribute type date model'
                    properties:
                        value:
                            type: string
                            format: date
                            nullable: true
                    type: object
        ApiAttributeTypeDateTimeEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: date-time
                    description: 'Attribute type date-time model'
                    properties:
                        value:
                            type: string
                            format: date-time
                            nullable: true
                    type: object
        ApiAttributeTypeEmailEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: email
                    description: 'Attribute type email model'
                    properties:
                        value:
                            title: 'list items'
                            description: 'string or array'
                            format: object
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectStringDM'
                                -
                                    $ref: '#/components/schemas/ApiObjectStringsDM'
                    type: object
        ApiAttributeTypeFileEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: file
                    description: 'Attribute type file model'
                    properties:
                        value:
                            title: files
                            description: 'integer or array'
                            format: object
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectIdDM'
                                -
                                    $ref: '#/components/schemas/ApiObjectIdsDM'
                    type: object
        ApiAttributeTypeFloatEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: float
                    description: 'Attribute type float model'
                    properties:
                        value:
                            type: number
                            format: number
                            nullable: true
                    type: object
        ApiAttributeTypeListEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: list
                    description: 'Attribute type list model'
                    properties:
                        value:
                            title: 'list position values'
                            description: 'integer or array'
                            format: object
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectIdDM'
                                -
                                    $ref: '#/components/schemas/ApiObjectIdsDM'
                    type: object
        ApiAttributeTypeListMultiEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: listMulti
                    description: 'Attribute type list multi model'
                    properties:
                        value:
                            title: 'list position values'
                            description: 'integer or array'
                            format: object
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectIdDM'
                                -
                                    $ref: '#/components/schemas/ApiObjectIdsDM'
                    type: object
        ApiAttributeTypePhoneEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: phone
                    description: 'Attribute type phone model'
                    properties:
                        value:
                            type: string
                            format: string
                    type: object
        ApiAttributeTypeSignatureEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: signature
                    description: 'Attribute type signature model'
                    properties:
                        value:
                            title: signatures
                            description: 'integer or array'
                            format: object
                            nullable: true
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectIdDM'
                                -
                                    $ref: '#/components/schemas/ApiObjectIdsDM'
                    type: object
        ApiAttributeTypeTagsEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: tags
                    description: 'Attribute type tags model'
                    properties:
                        value:
                            title: 'list items'
                            description: 'string or array'
                            format: object
                            nullable: true
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectStringDM'
                                -
                                    $ref: '#/components/schemas/ApiObjectStringsDM'
                    type: object
        ApiAttributeTypeTextEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: text
                    description: 'Attribute type text model'
                    properties:
                        value:
                            type: string
                            format: string
                            nullable: true
                    type: object
        ApiAttributeTypeUserUserEditDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeDM'
                -
                    title: 'user user'
                    description: 'Attribute type user user model'
                    properties:
                        value:
                            title: user_users
                            description: 'integer or array'
                            format: object
                            nullable: true
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectIdDM'
                                -
                                    $ref: '#/components/schemas/ApiObjectIdsDM'
                    type: object
        ApiAttributeTypeAccountUserShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: 'account user'
                    description: 'Attribute type account user model'
                    properties:
                        value:
                            title: account_users
                            description: ''
                            type: array
                            format: object
                            items:
                                $ref: '#/components/schemas/AccountUserAura'
                    type: object
        ApiAttributeTypeBoolShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: bool
                    description: 'Attribute type bool model'
                    properties:
                        value:
                            type: boolean
                            format: bool
                    type: object
        ApiAttributeTypeCompanyShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: company
                    description: 'Attribute type company model'
                    properties:
                        value:
                            title: companies
                            description: ''
                            type: array
                            format: object
                            items:
                                $ref: '#/components/schemas/AccountCompanyAura'
                    type: object
        ApiAttributeTypeDateShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: date
                    description: 'Attribute type date model'
                    properties:
                        value:
                            type: string
                            format: date
                            nullable: true
                    type: object
        ApiAttributeTypeDateTimeShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: date-time
                    description: 'Attribute type date-time model'
                    properties:
                        value:
                            type: string
                            format: date-time
                            nullable: true
                    type: object
        ApiAttributeTypeEmailShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: email
                    description: 'Attribute type email model'
                    properties:
                        value:
                            title: 'list items'
                            description: 'string or array'
                            format: object
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectStringDM'
                                -
                                    $ref: '#/components/schemas/ApiObjectStringsDM'
                    type: object
        ApiAttributeTypeFileShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: file
                    description: 'Attribute type file model'
                    properties:
                        value:
                            title: files
                            description: ''
                            type: array
                            format: object
                            items:
                                $ref: '#/components/schemas/FileAura'
                    type: object
        ApiAttributeTypeFloatShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: float
                    description: 'Attribute type float model'
                    properties:
                        value:
                            type: number
                            format: number
                            nullable: true
                    type: object
        ApiAttributeTypeListMultiShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: listMulti
                    description: 'Attribute type list multi model'
                    properties:
                        positions:
                            $ref: '#/components/schemas/ApiAttributeListPositionDM'
                        value:
                            $ref: '#/components/schemas/ApiAttributeListPositionValueDM'
                    type: object
        ApiAttributeTypeListShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: list
                    description: 'Attribute type list model'
                    properties:
                        positions:
                            $ref: '#/components/schemas/ApiAttributeListPositionDM'
                        value:
                            $ref: '#/components/schemas/ApiAttributeListPositionValueDM'
                    type: object
        ApiAttributeTypePhoneShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: phone
                    description: 'Attribute type phone model'
                    properties:
                        value:
                            type: string
                            format: string
                    type: object
        ApiAttributeTypeSignatureShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: signature
                    description: 'Attribute type signature model'
                    properties:
                        value:
                            title: signatures
                            description: ''
                            type: array
                            format: object
                            items:
                                $ref: '#/components/schemas/FileAura'
                    type: object
        ApiAttributeTypeTagsShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: tags
                    description: 'Attribute type tags model'
                    properties:
                        value:
                            title: 'list items'
                            description: 'string or array'
                            format: object
                            anyOf:
                                -
                                    $ref: '#/components/schemas/ApiObjectStringsDM'
                    type: object
        ApiAttributeTypeTextShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: text
                    description: 'Attribute type text model'
                    properties:
                        value:
                            type: string
                            format: string
                            nullable: true
                    type: object
        ApiAttributeTypeUserUserShowDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiAttributeShowDM'
                -
                    title: 'user user'
                    description: 'Attribute type user user model'
                    properties:
                        value:
                            title: user_users
                            description: ''
                            type: array
                            format: object
                            items:
                                $ref: '#/components/schemas/UserUserAura'
                    type: object
        ApiDataRequestDM:
            title: 'Data request model'
            description: 'Data request model'
            required:
                - data
            properties:
                data:
                    title: data
                    description: 'Data request, you can check the fields/ extra_fields and copy them from: /manual/api'
                    type: object
                    format: object
                setting:
                    $ref: '#/components/schemas/ApiSettingDM'
                fields:
                    title: fields
                    description: '(default: all) Fields in returned data. Limit it for the best performance. Max depth is 1'
                    type: string
                    format: string
                    example: 'field1,field2,parentField1.field3'
                extra_fields:
                    title: extra_fields
                    description: '(default: none) Extra fields in returned data. Max depth is 1'
                    type: string
                    format: string
                    example: 'extra_field1,extra_field2,parentField1.extra_field3'
            type: object
        ApiDataRequestFileDM:
            title: 'Data request model'
            description: 'Data request model'
            required:
                - data_files
            properties:
                data_files:
                    title: data_files
                    description: 'Files array'
                    type: array
                    items:
                        type: string
                        format: binary
                mode:
                    title: mode
                    description: '(default: 0) 0: temporary file, 1: attachment, 2: file'
                    type: integer
            type: object
        ApiDataRequestFileUrlDM:
            title: 'Data request model'
            description: 'Data request model'
            required:
                - data_files_urls
            properties:
                data_files_urls:
                    title: data_files_urls
                    description: 'URL array'
                    type: array
                    items:
                        type: string
            type: object
        ApiDataRequestGeneratePdfDM:
            allOf:
                -
                    $ref: '#/components/schemas/ApiDataRequestSimpleDM'
                -
                    title: 'Data request model'
                    description: 'Data request model'
                    properties:
                        data:
                            $ref: '#/components/schemas/ApiDataRequestGeneratePdfDataDM'
                    type: object
        ApiDataRequestGeneratePdfDataDM:
            title: 'Data model'
            description: 'Data model'
            properties:
                templateId:
                    title: templateId
                    description: '(default: null) commissionTemplate''s or productTemplate''s ID'
                    type: integer
            type: object
        ApiDataRequestSimpleDM:
            title: 'Data request model'
            description: 'Data request model'
            required:
                - data
            properties:
                data:
                    title: data
                    description: 'Data request'
                    type: object
                    format: object
                setting:
                    $ref: '#/components/schemas/ApiSettingDM'
            type: object
        ApiObjectIdDM:
            title: objectId
            description: objectId
            type: integer
            format: integer
            writeOnly: true
        ApiObjectIdsDM:
            title: array<ids>
            description: array<ids>
            type: array
            format: array
            items:
                type: integer
            writeOnly: true
        ApiObjectStringDM:
            title: string
            description: string
            type: string
            format: string
            writeOnly: true
        ApiObjectStringsDM:
            title: array<strings>
            description: array<strings>
            type: array
            format: array
            items:
                type: string
            writeOnly: true
        ApiSettingDM:
            title: 'Setting model'
            description: 'Setting model'
            properties:
                mode_relations_add:
                    title: mode_relations_add
                    description: '(default: false) In this mode, unsubmitted relations will not be deleted. (only for ManyToMany, OneToMany)'
                    type: boolean
                    format: boolean
                    example: false
                mode_relations_remove:
                    title: mode_relations_remove
                    description: '(default: false) In this mode, sent relations will be removed. (only for ManyToMany, OneToMany)'
                    type: boolean
                    format: boolean
                    example: false
                with_debug_mode:
                    title: with_debug_mode
                    description: '(default: false) API debug mode. Indicates exception paths and adds additional information to the meta object'
                    type: boolean
                    format: boolean
                    example: false
                with_editable_settings_for_action:
                    title: with_editable_settings_for_action
                    description: '(default: null) Determines whether to return editable API settings: meta.editableSettingsForAction.'
                    type: string
                    format: string
                    example: GET
                with_get_data:
                    title: with_get_data
                    description: '(default: true) Determines whether to return the *data* parameter. Disable it for best performance.'
                    type: boolean
                    format: boolean
                    example: true
                lang:
                    title: lang
                    description: '(default: pl) Defines the language of the client'
                    type: string
                    format: string
                    example: pl
                extend_request_with_additional_changed:
                    title: extend_request_with_additional_changed
                    description: '(default: false) Determines whether to extend the request with additional changed objects.'
                    type: boolean
                    format: boolean
                    example: false
                limit_to_my_settings:
                    title: limit_to_my_settings
                    description: '(default: true) Determines whether to limit user_settings and profile_settings to user''s settings. Only available for admins.'
                    type: boolean
                    format: boolean
                    example: false
            type: object
        TargetGETFieldsForCollection:
            title: targets
            type: object
            properties:
                id:
                    type: integer
                    nullable: false
                name:
                    type: string
                    nullable: false
                    maxLength: 255
                interval:
                    type: string
                    nullable: false
                    maxLength: 10
                    description: 'day, week, month, quarter, halfYear, year'
                beginDate:
                    type: string
                    nullable: false
                    format: date-time
                endDate:
                    type: string
                    nullable: false
                    format: date-time
                minReqCreds:
                    type: integer
                    nullable: false
                creatorUser:
                    nullable: false
                    description: (userUser)
                    allOf:
                        -
                            $ref: '#/components/schemas/UserUserGETFieldsForRelation'
                editorUser:
                    nullable: false
                    description: (userUser)
                    allOf:
                        -
                            $ref: '#/components/schemas/UserUserGETFieldsForRelation'
                targetDelegates:
                    nullable: false
                    description: (targetDelegates)
                    allOf:
                        -
                            $ref: '#/components/schemas/TargetDelegatesGETFieldsForRelation'
                targetObjectives:
                    nullable: false
                    description: (targetObjective)
                    allOf:
                        -
                            $ref: '#/components/schemas/TargetObjectiveGETFieldsForRelation'
        TargetGETExtra_fieldsForCollection:
            title: targets
            type: object
            properties:
                availableTemplates:
                    type: array
                    nullable: true
                    items:
                        type: integer
                    description: extra_field
        TargetGETFields:
            title: targets
            type: object
            properties:
                id:
                    type: integer
                    nullable: false
                name:
                    type: string
                    nullable: false
                    maxLength: 255
                interval:
                    type: string
                    nullable: false
                    maxLength: 10
                    description: 'day, week, month, quarter, halfYear, year'
                beginDate:
                    type: string
                    nullable: false
                    format: date-time
                endDate:
                    type: string
                    nullable: false
                    format: date-time
                minReqCreds:
                    type: integer
                    nullable: false
                creatorUser:
                    nullable: false
                    description: (userUser)
                    allOf:
                        -
                            $ref: '#/components/schemas/UserUserGETFieldsForRelation'
                editorUser:
                    nullable: false
                    description: (userUser)
                    allOf:
                        -
                            $ref: '#/components/schemas/UserUserGETFieldsForRelation'
                targetDelegates:
                    nullable: false
                    description: (targetDelegates)
                    allOf:
                        -
                            $ref: '#/components/schemas/TargetDelegatesGETFieldsForRelation'
                targetObjectives:
                    nullable: false
                    description: (targetObjective)
                    allOf:
                        -
                            $ref: '#/components/schemas/TargetObjectiveGETFieldsForRelation'
        TargetGETExtra_fields:
            title: targets
            type: object
            properties:
                availableTemplates:
                    type: array
                    nullable: true
                    items:
                        type: integer
                    description: extra_field
        TargetPATCHForCollection:
            title: targets
            type: array
            items:
                type: object
                properties:
                    id:
                        type: integer
                        nullable: false
                    name:
                        type: string
                        nullable: false
                        maxLength: 255
                    interval:
                        type: string
                        nullable: false
                        maxLength: 10
                        description: 'day, week, month, quarter, halfYear, year'
                    beginDate:
                        type: string
                        nullable: false
                        format: date-time
                    endDate:
                        type: string
                        nullable: false
                        format: date-time
                    targetDelegates:
                        nullable: false
                        description: 'integer or array<object> or object (targetDelegates)'
                        anyOf:
                            -
                                $ref: '#/components/schemas/ApiObjectIdDM'
                            -
                                type: array
                                items:
                                    $ref: '#/components/schemas/TargetDelegatesPATCHForRelation'
                    targetObjectives:
                        nullable: false
                        description: 'integer or array<object> or object (targetObjective)'
                        anyOf:
                            -
                                $ref: '#/components/schemas/ApiObjectIdDM'
                            -
                                type: array
                                items:
                                    $ref: '#/components/schemas/TargetObjectivePATCHForRelation'
                required:
                    - name
                    - interval
                    - beginDate
                    - endDate
        TargetPATCH:
            title: targets
            type: object
            properties:
                name:
                    type: string
                    nullable: false
                    maxLength: 255
                interval:
                    type: string
                    nullable: false
                    maxLength: 10
                    description: 'day, week, month, quarter, halfYear, year'
                beginDate:
                    type: string
                    nullable: false
                    format: date-time
                endDate:
                    type: string
                    nullable: false
                    format: date-time
                targetDelegates:
                    nullable: false
                    description: 'integer or array<object> or object (targetDelegates)'
                    anyOf:
                        -
                            $ref: '#/components/schemas/ApiObjectIdDM'
                        -
                            type: array
                            items:
                                $ref: '#/components/schemas/TargetDelegatesPATCHForRelation'
                targetObjectives:
                    nullable: false
                    description: 'integer or array<object> or object (targetObjective)'
                    anyOf:
                        -
                            $ref: '#/components/schemas/ApiObjectIdDM'
                        -
                            type: array
                            items:
                                $ref: '#/components/schemas/TargetObjectivePATCHForRelation'
            required:
                - name
                - interval
                - beginDate
                - endDate
        TargetPOSTForCollection:
            title: targets
            type: array
            items:
                type: object
                properties:
                    name:
                        type: string
                        nullable: false
                        maxLength: 255
                    interval:
                        type: string
                        nullable: false
                        maxLength: 10
                        description: 'day, week, month, quarter, halfYear, year'
                    beginDate:
                        type: string
                        nullable: false
                        format: date-time
                    endDate:
                        type: string
                        nullable: false
                        format: date-time
                    targetDelegates:
                        nullable: false
                        description: 'integer or array<object> or object (targetDelegates)'
                        anyOf:
                            -
                                $ref: '#/components/schemas/ApiObjectIdDM'
                            -
                                type: array
                                items:
                                    $ref: '#/components/schemas/TargetDelegatesPOSTForRelation'
                    targetObjectives:
                        nullable: false
                        description: 'integer or array<object> or object (targetObjective)'
                        anyOf:
                            -
                                $ref: '#/components/schemas/ApiObjectIdDM'
                            -
                                type: array
                                items:
                                    $ref: '#/components/schemas/TargetObjectivePOSTForRelation'
                required:
                    - name
                    - interval
                    - beginDate
                    - endDate
        TargetPOST:
            title: targets
            type: object
            properties:
                name:
                    type: string
                    nullable: false
                    maxLength: 255
                interval:
                    type: string
                    nullable: false
                    maxLength: 10
                    description: 'day, week, month, quarter, halfYear, year'
                beginDate:
                    type: string
                    nullable: false
                    format: date-time
                endDate:
                    type: string
                    nullable: false
                    format: date-time
                targetDelegates:
                    nullable: false
                    description: 'integer or array<object> or object (targetDelegates)'
                    anyOf:
                        -
                            $ref: '#/components/schemas/ApiObjectIdDM'
                        -
                            type: array
                            items:
                                $ref: '#/components/schemas/TargetDelegatesPOSTForRelation'
                targetObjectives:
                    nullable: false
                    description: 'integer or array<object> or object (targetObjective)'
                    anyOf:
                        -
                            $ref: '#/components/schemas/ApiObjectIdDM'
                        -
                            type: array
                            items:
                                $ref: '#/components/schemas/TargetObjectivePOSTForRelation'
            required:
                - name
                - interval
                - beginDate
                - endDate
        UserUserGETFieldsForRelation:
            title: user_users
            type: object
            properties:
                id:
                    type: integer
                    nullable: false
                username:
                    type: string
                    nullable: false
                    maxLength: 50
                email:
                    type: string
                    nullable: true
                    maxLength: 50
                firstName:
                    type: string
                    nullable: true
                    maxLength: 25
                lastName:
                    type: string
                    nullable: true
                    maxLength: 35
                avatar:
                    type: string
                    nullable: true
                    maxLength: 50
                verified:
                    type: string
                    nullable: true
                    maxLength: 255
                sessionId:
                    type: string
                    nullable: true
                    maxLength: 75
                lastAction:
                    type: string
                    nullable: true
                    format: date-time
                loggedIn:
                    type: boolean
                    nullable: true
                messageOnEmail:
                    type: boolean
                    nullable: true
                phoneNumber:
                    type: string
                    nullable: true
                    maxLength: 15
                mobileNumber:
                    type: string
                    nullable: true
                    maxLength: 15
                defaultCurrency:
                    type: string
                    nullable: true
                    maxLength: 15
                availableCurrencies:
                    type: string
                    nullable: true
                importId:
                    type: integer
                    nullable: true
                    description: 'Id from external system'
                importTyp:
                    type: string
                    nullable: true
                    description: 'External system name'
                language:
                    type: string
                    nullable: true
                    maxLength: 30
                lastLoginDate:
                    type: string
                    nullable: true
                    format: date-time
                lastLogoutDate:
                    type: string
                    nullable: true
                    format: date-time
                failedLoginCounter:
                    type: integer
                    nullable: true
                lastFailedLogin:
                    type: string
                    nullable: true
                    format: date-time
                defaultCallendarColor:
                    type: string
                    nullable: true
                    maxLength: 50
                resetLinkExpires:
                    type: string
                    nullable: true
                    format: date-time
                activeCurrency:
                    type: string
                    nullable: true
                    maxLength: 15
                systemTheme:
                    type: string
                    nullable: true
                    maxLength: 50
                isExternalLogin:
                    type: boolean
                    nullable: true
                importCode:
                    type: string
                    nullable: true
                    maxLength: 255
                    description: 'Code from external system'
                modificationDate:
                    type: string
                    nullable: true
                    format: date-time
                msexchange:
                    type: boolean
                    nullable: true
                uri:
                    type: string
                    nullable: true
                avatarFile:
                    type: object
                    nullable: true
                    description: (file)
                defaultCssFile:
                    type: object
                    nullable: true
                    description: (file)
                superior:
                    type: object
                    nullable: true
                    description: (userUser)
                userProfile:
                    type: object
                    nullable: true
                    description: (userProfile)
        UserUserGETExtra_fieldsForRelation:
            title: user_users
            type: object
            properties:
                availableTemplates:
                    type: array
                    nullable: true
                    items:
                        type: integer
                    description: extra_field
                fullName:
                    type: string
                    nullable: true
                    description: extra_field
                subordinates:
                    type: array
                    nullable: true
                    items:
                        type: integer
                    description: extra_field
        TargetDelegatesGETFieldsForRelation:
            title: target_delegatess
            type: object
            properties:
                id:
                    type: integer
                    nullable: false
                target:
                    type: object
                    nullable: false
                    description: (target)
                userUser:
                    type: object
                    nullable: true
                    description: (userUser)
                receiverGroup:
                    type: object
                    nullable: true
                    description: (receiverGroup)
        TargetDelegatesGETExtra_fieldsForRelation:
            title: target_delegatess
            type: object
            properties:
                availableTemplates:
                    type: array
                    nullable: true
                    items:
                        type: integer
                    description: extra_field
        TargetObjectiveGETFieldsForRelation:
            title: target_objectives
            type: object
            properties:
                id:
                    type: integer
                    nullable: false
                name:
                    type: string
                    nullable: true
                    maxLength: 255
                type:
                    type: string
                    nullable: false
                    description: 'eventCount, saleValue, customSQL'
                config:
                    type: string
                    nullable: true
                    description: '**For type eventCount:** <br />"goal": (float)<br />"taskType": (integer - taskType.id)<br /><br />**For type saleValue:** <br />"goal": (float)<br />"documentSeriesDefinitions": (integer[] - documentSeriesDefinition.id)<br />"sumAsMainPh": (boolean)<br /><br />**For type customSQL:** <br />"goalSQL": (string)<br />"customSQL": (string)<br />'
                target:
                    type: object
                    nullable: false
                    description: (target)
        TargetObjectiveGETExtra_fieldsForRelation:
            title: target_objectives
            type: object
            properties:
                availableTemplates:
                    type: array
                    nullable: true
                    items:
                        type: integer
                    description: extra_field
        TargetDelegatesPATCHForRelation:
            title: target_delegatess
            type: object
            properties:
                id:
                    type: integer
                    nullable: false
                target:
                    type: integer
                    nullable: false
                    description: 'integer or object (target)'
                userUser:
                    type: integer
                    nullable: true
                    description: 'integer or object (userUser)'
                receiverGroup:
                    type: integer
                    nullable: true
                    description: 'integer or object (receiverGroup)'
            required:
                - target
        TargetObjectivePATCHForRelation:
            title: target_objectives
            type: object
            properties:
                id:
                    type: integer
                    nullable: false
                name:
                    type: string
                    nullable: true
                    maxLength: 255
                type:
                    type: string
                    nullable: false
                    description: 'eventCount, saleValue, customSQL'
                config:
                    type: string
                    nullable: true
                    description: '**For type eventCount:** <br />"goal": (float)<br />"taskType": (integer - taskType.id)<br /><br />**For type saleValue:** <br />"goal": (float)<br />"documentSeriesDefinitions": (integer[] - documentSeriesDefinition.id)<br />"sumAsMainPh": (boolean)<br /><br />**For type customSQL:** <br />"goalSQL": (string)<br />"customSQL": (string)<br />'
                target:
                    type: integer
                    nullable: false
                    description: 'integer or object (target)'
            required:
                - type
                - target
        TargetDelegatesPOSTForRelation:
            title: target_delegatess
            type: object
            properties:
                id:
                    type: integer
                    nullable: false
                target:
                    type: integer
                    nullable: false
                    description: 'integer or object (target)'
                userUser:
                    type: integer
                    nullable: true
                    description: 'integer or object (userUser)'
                receiverGroup:
                    type: integer
                    nullable: true
                    description: 'integer or object (receiverGroup)'
            required:
                - target
        TargetObjectivePOSTForRelation:
            title: target_objectives
            type: object
            properties:
                id:
                    type: integer
                    nullable: false
                name:
                    type: string
                    nullable: true
                    maxLength: 255
                type:
                    type: string
                    nullable: false
                    description: 'eventCount, saleValue, customSQL'
                config:
                    type: string
                    nullable: true
                    description: '**For type eventCount:** <br />"goal": (float)<br />"taskType": (integer - taskType.id)<br /><br />**For type saleValue:** <br />"goal": (float)<br />"documentSeriesDefinitions": (integer[] - documentSeriesDefinition.id)<br />"sumAsMainPh": (boolean)<br /><br />**For type customSQL:** <br />"goalSQL": (string)<br />"customSQL": (string)<br />'
                target:
                    type: integer
                    nullable: false
                    description: 'integer or object (target)'
            required:
                - type
                - target
    parameters:
        module:
            name: module
            in: path
            description: 'API module (account_companies, commissions, ...)'
            required: true
            schema:
                type: string
        id:
            name: id
            in: path
            description: 'PK (1, 2, 3...)'
            required: true
            schema:
                type: integer
        name:
            name: name
            in: path
            description: 'Value of the name column'
            required: true
            schema:
                type: string
        fields:
            name: fields
            in: query
            description: '(default: all fields) These fields will appear in the output data. If you enter fields that do not exist, they will be ignored. The field related to PK will be added automatically.<br />**Query example:** fields=name,shortName,accountUsers.firstName'
            style: form
            explode: false
            schema:
                type: array
                items:
                    type: string
        extra_fields:
            name: extra_fields
            in: query
            description: 'This is a field created on the API side that does not appear in the database (e.g. is a combination of other fields).<br />**Query example:** extra_fields=fullName'
            style: form
            explode: false
            schema:
                type: array
                items:
                    type: string
        filter:
            name: filter
            in: query
            description: 'Data filtering for the case: A and B and C and D. <br />Filter types: <ul><li>eq - equal, you can ignore this parameter in query,</li><li>neq - different from</li><li>lt - less than</li><li>lte - smaller, equal to from</li><li>gt - exceed from</li><li>gte - much, equal from</li><li>isNull - is empty (you cannot enter a filter value)</li><li>isNotNull - is non-empty (do not specify filter value)</li><li>in - belongs to (filter value should be an array)</li><li>notIn - does not belong to (filter value should be an array)</li><li>like - equal word expressed (you can use a query with e.g.%, remember only about proper URL formatting)</li><li>ilike - LIKE, which is case insensitive (UPPER function)</li><li>notLike - uneven word expressed (you can use here a query with e.g.%, you should only remember about proper URL formatting)</li><li>hasText - (like ilike), %% is added to search</li></ul>**Query example:** filter[accountUsers.id][isNotNull]&filter[name][ilike]=guest&filter[id]=88550'
            style: deepObject
            schema:
                type: object
                items:
                    type: object
        filterOr:
            name: filterOr
            in: query
            description: 'Data filtering for the case: (A or B) and (C or D).<br />Parameter template: filterOr[index][filter]<br /> * index - integer, defines a group of filters between which an OR will be applied. You can ignore this if you only want one OR group in the query.<br /> * filter - filter array<br /><br />AND will be used between defined groups.<br /><br />**Simple example:** We want to return products whose name is equal to ''others'' or the code contains ''c'' so we can query endpoint /products with the following parameters:<br />filterOr[name]=others<br />&filterOr[code][hasText]=c<br /><br />**Example:** We want to return products whose name is equal to ''service'' or the code contains ''c'' AND the name is equal to ''service'' or the code contains ''s'' or the id is equal to 1, 2 or 3 so we can query endpoint /products with the following parameters:<br />filterOr[0][name]=service<br />&filterOr[0][code][hasText]=c<br />&filterOr[1][name]=service<br />&filterOr[1][code][hasText]=s<br />&filterOr[1][id][in]=1,2,3'
            style: deepObject
            schema:
                type: object
                items:
                    type: object
        filterAnd:
            name: filterAnd
            in: query
            description: 'Data filtering for the case: (A and B) or (C and D).<br />Parameter template: filterAnd[index][filter]<br /> * index - integer, defines a group of filters between which an AND will be applied. If you only want one AND group in the query - you should use parameter filter instead.<br /> * filter - filter array<br /><br />OR will be used between defined groups.<br /><br />**Example:** We want to return products whose name is equal to ''service'' and the code is equal to ''ser01'' OR the name is equal to ''others'' and the code is equal to ''oth02'' so we can query endpoint /products with the following parameters:<br />filterAnd[0][name]=service<br />&filterAnd[0][code]=ser01<br />&filterAnd[1][name]=others<br />&filterAnd[1][code]=oth02'
            style: deepObject
            schema:
                type: object
                items:
                    type: object
        order:
            name: order
            in: query
            description: '(default: sort by PK) Data sorting. Sort types: <ul><li>asc,</li><li>desc.</li></ul>**Query example:** order[name]=asc&order[shortName]=desc'
            style: deepObject
            schema:
                type: object
                items:
                    type: string
        modules:
            name: modules
            in: query
            description: 'Module list. <br />**Query example:** modules[id1]=account_users&modules[id2]=user_users'
            required: true
            style: deepObject
            schema:
                type: object
                items:
                    type: string
        modules_params:
            name: modules_params
            in: query
            description: 'Module params. <br />**Query example:** modules_params[id1][filter][id][eq]=1&modules_params[id2][order][id]=desc'
            style: deepObject
            schema:
                type: object
                items:
                    type: object
        contextModule:
            name: contextModule
            in: path
            description: 'Context API module (account_companies, commissions, ...)'
            required: true
            schema:
                type: string
        contextId:
            name: contextId
            in: path
            description: 'Context PK (1, 2, 3, ...)'
            required: true
            schema:
                type: integer
        setting_with_relations:
            name: 'setting[with_relations]'
            in: query
            description: '(default: false) Determines whether the query (GET) should contain joins to related tables'
            schema:
                type: boolean
        setting_with_debug_mode:
            name: 'setting[with_debug_mode]'
            in: query
            description: '(default: false) API debug mode. Indicates exception paths and adds additional information to the meta object'
            schema:
                type: boolean
        setting_with_editable_settings_for_action:
            name: 'setting[with_editable_settings_for_action]'
            in: query
            description: '(default: null) Determines whether to return editable API settings in: meta.editableSettingsForAction.'
            schema:
                type: string
        setting_lang:
            name: 'setting[lang]'
            in: query
            description: '(default: pl) Defines the language of the client'
            schema:
                type: string
        setting_email_messages_mark_seen:
            name: 'setting[email_messages_mark_seen]'
            in: query
            description: '(default: false) Determines whether to mark the email messages as seen'
            schema:
                type: boolean
        setting_with_cache:
            name: 'setting[with_cache]'
            in: query
            description: '(default: false) Determines whether load email messages from the database (cache) if its is up-to-date.'
            deprecated: true
            schema:
                type: boolean
        setting_email_messages_save_in_db:
            name: 'setting[email_messages_save_in_db]'
            in: query
            description: '(default: false) Determines whether to create or update the email messages in the database (cache).'
            schema:
                type: boolean
        setting_email_messages_check_in_db:
            name: 'setting[email_messages_check_in_db]'
            in: query
            description: '(default: false) Determines whether to update email messages in the database (cache). If the email message does not exist the API will return an empty identifier.'
            schema:
                type: boolean
        setting_limit_to_my_settings:
            name: 'setting[limit_to_my_settings]'
            in: query
            description: '(default: true) Determines whether to limit user_settings and profile_settings to user''s settings. Only available for admins.'
            schema:
                type: boolean
        page_limit:
            name: 'page[limit]'
            in: query
            description: '(default: 20) LIMIT - data limit.'
            schema:
                type: integer
        page_offset:
            name: 'page[offset]'
            in: query
            description: 'OFFSET - data offset'
            schema:
                type: integer
        page_number:
            name: 'page[number]'
            in: query
            description: '(default: 1) Page number (starts from 1)'
            schema:
                type: integer
        for_fieldName:
            name: 'for[fieldName]'
            in: query
            description: 'Determines for which field values the meta data will be returned. <br />The for [id] parameter will cause the metadata to be returned for a specific object. It is possible to simulate an object change. <br />Some modules or extra_fields require specific keys to be sent. Information about these fields will be returned from the API. <br />**Query example:** for[id]=1&for[commissionPhase]=1'
            schema:
                type: integer
        TargetGETFieldsForCollection:
            name: fields
            in: query
            description: '(default: all fields) These fields will appear in the output data. If you enter fields that do not exist, they will be ignored. The field related to PK will be added automatically.<br />**Query example:** fields=name,shortName,accountUsers.firstName'
            style: form
            explode: false
            schema:
                $ref: '#/components/schemas/TargetGETFieldsForCollection'
        TargetGETExtra_fieldsForCollection:
            name: extra_fields
            in: query
            description: 'This is a field created on the API side that does not appear in the database (e.g. is a combination of other fields).<br />**Query example:** extra_fields=fullName'
            style: form
            explode: false
            schema:
                $ref: '#/components/schemas/TargetGETExtra_fieldsForCollection'
        TargetGETFields:
            name: fields
            in: query
            description: '(default: all fields) These fields will appear in the output data. If you enter fields that do not exist, they will be ignored. The field related to PK will be added automatically.<br />**Query example:** fields=name,shortName,accountUsers.firstName'
            style: form
            explode: false
            schema:
                $ref: '#/components/schemas/TargetGETFields'
        TargetGETExtra_fields:
            name: extra_fields
            in: query
            description: 'This is a field created on the API side that does not appear in the database (e.g. is a combination of other fields).<br />**Query example:** extra_fields=fullName'
            style: form
            explode: false
            schema:
                $ref: '#/components/schemas/TargetGETExtra_fields'
        UserUserGETFieldsForRelation:
            name: fields
            in: query
            description: '(default: all fields) These fields will appear in the output data. If you enter fields that do not exist, they will be ignored. The field related to PK will be added automatically.<br />**Query example:** fields=name,shortName,accountUsers.firstName'
            style: form
            explode: false
            schema:
                $ref: '#/components/schemas/UserUserGETFieldsForRelation'
        UserUserGETExtra_fieldsForRelation:
            name: extra_fields
            in: query
            description: 'This is a field created on the API side that does not appear in the database (e.g. is a combination of other fields).<br />**Query example:** extra_fields=fullName'
            style: form
            explode: false
            schema:
                $ref: '#/components/schemas/UserUserGETExtra_fieldsForRelation'
        TargetDelegatesGETFieldsForRelation:
            name: fields
            in: query
            description: '(default: all fields) These fields will appear in the output data. If you enter fields that do not exist, they will be ignored. The field related to PK will be added automatically.<br />**Query example:** fields=name,shortName,accountUsers.firstName'
            style: form
            explode: false
            schema:
                $ref: '#/components/schemas/TargetDelegatesGETFieldsForRelation'
        TargetDelegatesGETExtra_fieldsForRelation:
            name: extra_fields
            in: query
            description: 'This is a field created on the API side that does not appear in the database (e.g. is a combination of other fields).<br />**Query example:** extra_fields=fullName'
            style: form
            explode: false
            schema:
                $ref: '#/components/schemas/TargetDelegatesGETExtra_fieldsForRelation'
        TargetObjectiveGETFieldsForRelation:
            name: fields
            in: query
            description: '(default: all fields) These fields will appear in the output data. If you enter fields that do not exist, they will be ignored. The field related to PK will be added automatically.<br />**Query example:** fields=name,shortName,accountUsers.firstName'
            style: form
            explode: false
            schema:
                $ref: '#/components/schemas/TargetObjectiveGETFieldsForRelation'
        TargetObjectiveGETExtra_fieldsForRelation:
            name: extra_fields
            in: query
            description: 'This is a field created on the API side that does not appear in the database (e.g. is a combination of other fields).<br />**Query example:** extra_fields=fullName'
            style: form
            explode: false
            schema:
                $ref: '#/components/schemas/TargetObjectiveGETExtra_fieldsForRelation'
    requestBodies:
        RequestBodyPost:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        $ref: '#/components/schemas/ApiDataRequestDM'
        RequestBodyFilePost:
            description: ''
            required: true
            content:
                multipart/form-data:
                    schema:
                        allOf:
                            -
                                $ref: '#/components/schemas/ApiDataRequestFileDM'
        RequestBodyFileUrlPost:
            description: ''
            required: true
            content:
                multipart/form-data:
                    schema:
                        allOf:
                            -
                                $ref: '#/components/schemas/ApiDataRequestFileUrlDM'
        RequestGeneratePdf:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        $ref: '#/components/schemas/ApiDataRequestGeneratePdfDM'
        RequestBodySimplePost:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        $ref: '#/components/schemas/ApiDataRequestSimpleDM'
        TargetPATCHForCollectionRequestBody:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        title: 'Data request model'
                        description: 'Data request model'
                        required:
                            - data
                        properties:
                            data:
                                $ref: '#/components/schemas/TargetPATCHForCollection'
                            setting:
                                $ref: '#/components/schemas/ApiSettingDM'
                            fields:
                                title: fields
                                description: '(default: all) Fields in returned data. Limit it for the best performance. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetGETFieldsForCollection'
                            extra_fields:
                                title: extra_fields
                                description: '(default: none) Extra fields in returned data. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetGETExtra_fieldsForCollection'
                        type: object
        TargetPATCHRequestBody:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        title: 'Data request model'
                        description: 'Data request model'
                        required:
                            - data
                        properties:
                            data:
                                $ref: '#/components/schemas/TargetPATCH'
                            setting:
                                $ref: '#/components/schemas/ApiSettingDM'
                            fields:
                                title: fields
                                description: '(default: all) Fields in returned data. Limit it for the best performance. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetGETFields'
                            extra_fields:
                                title: extra_fields
                                description: '(default: none) Extra fields in returned data. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetGETExtra_fields'
                        type: object
        TargetPOSTForCollectionRequestBody:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        title: 'Data request model'
                        description: 'Data request model'
                        required:
                            - data
                        properties:
                            data:
                                $ref: '#/components/schemas/TargetPOSTForCollection'
                            setting:
                                $ref: '#/components/schemas/ApiSettingDM'
                            fields:
                                title: fields
                                description: '(default: all) Fields in returned data. Limit it for the best performance. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetGETFieldsForCollection'
                            extra_fields:
                                title: extra_fields
                                description: '(default: none) Extra fields in returned data. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetGETExtra_fieldsForCollection'
                        type: object
        TargetPOSTRequestBody:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        title: 'Data request model'
                        description: 'Data request model'
                        required:
                            - data
                        properties:
                            data:
                                $ref: '#/components/schemas/TargetPOST'
                            setting:
                                $ref: '#/components/schemas/ApiSettingDM'
                            fields:
                                title: fields
                                description: '(default: all) Fields in returned data. Limit it for the best performance. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetGETFields'
                            extra_fields:
                                title: extra_fields
                                description: '(default: none) Extra fields in returned data. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetGETExtra_fields'
                        type: object
        TargetDelegatesPATCHForRelationRequestBody:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        title: 'Data request model'
                        description: 'Data request model'
                        required:
                            - data
                        properties:
                            data:
                                $ref: '#/components/schemas/TargetDelegatesPATCHForRelation'
                            setting:
                                $ref: '#/components/schemas/ApiSettingDM'
                            fields:
                                title: fields
                                description: '(default: all) Fields in returned data. Limit it for the best performance. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetDelegatesGETFieldsForRelation'
                            extra_fields:
                                title: extra_fields
                                description: '(default: none) Extra fields in returned data. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetDelegatesGETExtra_fieldsForRelation'
                        type: object
        TargetObjectivePATCHForRelationRequestBody:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        title: 'Data request model'
                        description: 'Data request model'
                        required:
                            - data
                        properties:
                            data:
                                $ref: '#/components/schemas/TargetObjectivePATCHForRelation'
                            setting:
                                $ref: '#/components/schemas/ApiSettingDM'
                            fields:
                                title: fields
                                description: '(default: all) Fields in returned data. Limit it for the best performance. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetObjectiveGETFieldsForRelation'
                            extra_fields:
                                title: extra_fields
                                description: '(default: none) Extra fields in returned data. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetObjectiveGETExtra_fieldsForRelation'
                        type: object
        TargetDelegatesPOSTForRelationRequestBody:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        title: 'Data request model'
                        description: 'Data request model'
                        required:
                            - data
                        properties:
                            data:
                                $ref: '#/components/schemas/TargetDelegatesPOSTForRelation'
                            setting:
                                $ref: '#/components/schemas/ApiSettingDM'
                            fields:
                                title: fields
                                description: '(default: all) Fields in returned data. Limit it for the best performance. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetDelegatesGETFieldsForRelation'
                            extra_fields:
                                title: extra_fields
                                description: '(default: none) Extra fields in returned data. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetDelegatesGETExtra_fieldsForRelation'
                        type: object
        TargetObjectivePOSTForRelationRequestBody:
            description: ''
            required: true
            content:
                application/json:
                    schema:
                        title: 'Data request model'
                        description: 'Data request model'
                        required:
                            - data
                        properties:
                            data:
                                $ref: '#/components/schemas/TargetObjectivePOSTForRelation'
                            setting:
                                $ref: '#/components/schemas/ApiSettingDM'
                            fields:
                                title: fields
                                description: '(default: all) Fields in returned data. Limit it for the best performance. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetObjectiveGETFieldsForRelation'
                            extra_fields:
                                title: extra_fields
                                description: '(default: none) Extra fields in returned data. Max depth is 1'
                                allOf:
                                    -
                                        $ref: '#/components/schemas/TargetObjectiveGETExtra_fieldsForRelation'
                        type: object
    securitySchemes:
        bearerAuth:
            type: apiKey
            description: 'Get JWT token from: /security/login (GET request for get form)<br />Include in header -> Authorization: Bearer aaa.bbb.ccc'
            name: Authorization
            in: header
tags:
    -
        name: Target
