openapi: 3.2.0 info: title: Fenergo User Preference API version: '1.0' description: 'Operations tagged UserPreference across 2 of this provider''s published API definitions: fenergo-localisationcommand-v1-0-openapi.json, fenergo-localisationquery-v1-0-openapi.json. Each path carries the servers of the definition it was published in.' servers: - url: /localisationcommand - url: /localisationquery security: - Bearer: [] tags: - name: UserPreference paths: /api/userpreference: put: tags: - UserPreference summary: Create or Update the user language preference description: 'This method creates or updates the user language preference. If a user has not selected a language then tenant default language will be used.' operationId: UpdateUserPreference parameters: - name: X-TENANT-ID in: header description: The UiD of the tenant representing organization required: true schema: type: string example: b11f8be3-f29b-4959-8964-956d4af7c468 requestBody: content: application/json: schema: $ref: '#/components/schemas/CreateUserPreferenceDtoServiceRequest' text/json: schema: $ref: '#/components/schemas/CreateUserPreferenceDtoServiceRequest' application/*+json: schema: $ref: '#/components/schemas/CreateUserPreferenceDtoServiceRequest' responses: '202': description: Accepted for processing content: text/plain: schema: $ref: '#/components/schemas/UserPreferenceDtoServiceResponse' application/json: schema: $ref: '#/components/schemas/UserPreferenceDtoServiceResponse' text/json: schema: $ref: '#/components/schemas/UserPreferenceDtoServiceResponse' '400': description: Invalid request content: text/plain: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' application/json: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' text/json: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' '401': description: User is not authorized to perform this request content: application/json: example: message: Unauthorized '403': description: Access to resource is forbidden. content: application/json: schema: $ref: '#/components/schemas/ObjectServiceResponse' example: data: {} messages: - message: 'Access denied. Following permissions are required: Permission1, Permission2' type: Forbidden errorCode: Error Code '500': description: Internal server exception. Please, contact your provider. content: application/json: schema: $ref: '#/components/schemas/ObjectServiceResponse' example: data: null messages: - message: Internal server exception. Please, contact your provider. type: Error errorCode: INTERNAL_SERVER_ERROR '410': description: Endpoint marked as deprecated was terminated. This response will be present only if the endpoint was marked as deprecated and has reached the sunset date. During the deprecation period, the API will include additional 'sunset' and 'deprecation' headers. content: application/json: schema: $ref: '#/components/schemas/StringServiceResponse' example: data: null messages: - message: This endpoint is obsolete and was terminated on yyyy-MM-dd type: Error errorCode: OBSOLETE_ENDPOINT delete: tags: - UserPreference summary: Delete the user language preference description: 'This method delete the user language preference. If a user has not selected a language then tenant default language will be used.' operationId: DeleteUserPreference parameters: - name: X-TENANT-ID in: header description: The UiD of the tenant representing organization required: true schema: type: string example: b11f8be3-f29b-4959-8964-956d4af7c468 responses: '202': description: Accepted for processing '400': description: Invalid request content: text/plain: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' application/json: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' text/json: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' '404': description: Resource not found content: application/json: schema: $ref: '#/components/schemas/ObjectServiceResponse' example: data: {} messages: - message: User does not exists type: Error errorCode: Error Code '401': description: User is not authorized to perform this request content: application/json: example: message: Unauthorized '403': description: Access to resource is forbidden. content: application/json: schema: $ref: '#/components/schemas/ObjectServiceResponse' example: data: {} messages: - message: 'Access denied. Following permissions are required: Permission1, Permission2' type: Forbidden errorCode: Error Code '500': description: Internal server exception. Please, contact your provider. content: application/json: schema: $ref: '#/components/schemas/ObjectServiceResponse' example: data: null messages: - message: Internal server exception. Please, contact your provider. type: Error errorCode: INTERNAL_SERVER_ERROR '410': description: Endpoint marked as deprecated was terminated. This response will be present only if the endpoint was marked as deprecated and has reached the sunset date. During the deprecation period, the API will include additional 'sunset' and 'deprecation' headers. content: application/json: schema: $ref: '#/components/schemas/StringServiceResponse' example: data: null messages: - message: This endpoint is obsolete and was terminated on yyyy-MM-dd type: Error errorCode: OBSOLETE_ENDPOINT get: tags: - UserPreference summary: Get user language preference description: 'This method returns the user language preference. If the user had selected system language then the LanguageId will be 00000000-0000-0000-0000-000000000000' operationId: GetUserPreference parameters: - name: X-TENANT-ID in: header description: The UiD of the tenant representing organization required: true schema: type: string example: b11f8be3-f29b-4959-8964-956d4af7c468 responses: '200': description: Success. A UserPreference is returned content: text/plain: schema: $ref: '#/components/schemas/UserPreferenceDtoServiceResponse_2' application/json: schema: $ref: '#/components/schemas/UserPreferenceDtoServiceResponse_2' text/json: schema: $ref: '#/components/schemas/UserPreferenceDtoServiceResponse_2' '400': description: Bad request. The request has missing/invalid values content: text/plain: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' application/json: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' text/json: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' '401': description: User is not authorized to perform this request content: application/json: example: message: Unauthorized '403': description: Access to resource is forbidden. content: application/json: schema: $ref: '#/components/schemas/ObjectServiceResponse' example: data: {} messages: - message: 'Access denied. Following permissions are required: Permission1, Permission2' type: Forbidden errorCode: Error Code '500': description: Internal server exception. Please, contact your provider. content: application/json: schema: $ref: '#/components/schemas/ObjectServiceResponse' example: data: null messages: - message: Internal server exception. Please, contact your provider. type: Error errorCode: INTERNAL_SERVER_ERROR '410': description: Endpoint marked as deprecated was terminated. This response will be present only if the endpoint was marked as deprecated and has reached the sunset date. During the deprecation period, the API will include additional 'sunset' and 'deprecation' headers. content: application/json: schema: $ref: '#/components/schemas/StringServiceResponse' example: data: null messages: - message: This endpoint is obsolete and was terminated on yyyy-MM-dd type: Error errorCode: OBSOLETE_ENDPOINT servers: - url: /localisationcommand /api/userpreference/systemdefault: put: tags: - UserPreference summary: Set user localisation to System Language description: This method update user localisation to system language. operationId: UpdateUserPreferenceToSystemDefault parameters: - name: X-TENANT-ID in: header description: The UiD of the tenant representing organization required: true schema: type: string example: b11f8be3-f29b-4959-8964-956d4af7c468 responses: '202': description: Accepted for processing content: text/plain: schema: $ref: '#/components/schemas/UserPreferenceDtoServiceResponse' application/json: schema: $ref: '#/components/schemas/UserPreferenceDtoServiceResponse' text/json: schema: $ref: '#/components/schemas/UserPreferenceDtoServiceResponse' '400': description: Invalid request content: text/plain: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' application/json: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' text/json: schema: $ref: '#/components/schemas/ValidationErrorModelListServiceResponse' '401': description: User is not authorized to perform this request content: application/json: example: message: Unauthorized '403': description: Access to resource is forbidden. content: application/json: schema: $ref: '#/components/schemas/ObjectServiceResponse' example: data: {} messages: - message: 'Access denied. Following permissions are required: Permission1, Permission2' type: Forbidden errorCode: Error Code '500': description: Internal server exception. Please, contact your provider. content: application/json: schema: $ref: '#/components/schemas/ObjectServiceResponse' example: data: null messages: - message: Internal server exception. Please, contact your provider. type: Error errorCode: INTERNAL_SERVER_ERROR '410': description: Endpoint marked as deprecated was terminated. This response will be present only if the endpoint was marked as deprecated and has reached the sunset date. During the deprecation period, the API will include additional 'sunset' and 'deprecation' headers. content: application/json: schema: $ref: '#/components/schemas/StringServiceResponse' example: data: null messages: - message: This endpoint is obsolete and was terminated on yyyy-MM-dd type: Error errorCode: OBSOLETE_ENDPOINT servers: - url: /localisationcommand components: schemas: ValidationErrorModelListServiceResponse: type: object properties: data: type: - array - 'null' items: $ref: '#/components/schemas/ValidationErrorModel' messages: type: - array - 'null' items: $ref: '#/components/schemas/ServiceResponseMessage' additionalProperties: false example: data: - propertyName: data errorMessage: Data is required attemptedValue: '' errorCode: NotNullValidator messages: - message: Data is required type: Error errorCode: Error Code UserPreferenceDtoServiceResponse: type: object properties: data: $ref: '#/components/schemas/UserPreferenceDto' messages: type: - array - 'null' items: $ref: '#/components/schemas/ServiceResponseMessage' additionalProperties: false CreateUserPreferenceDto: required: - localisationId type: object properties: localisationId: type: string description: Selected Localisation Id format: uuid additionalProperties: false ValidationErrorModel: type: object properties: propertyName: type: - string - 'null' errorMessage: type: - string - 'null' attemptedValue: {} errorCode: type: - string - 'null' additionalProperties: false ServiceResponseMessage: type: object properties: message: type: - string - 'null' type: type: - string - 'null' errorCode: type: - string - 'null' additionalProperties: false UserPreferenceDto: type: object properties: id: type: string description: UserPreference Model Id format: uuid userId: type: - string - 'null' description: User Id localisationId: type: string description: Selected Localisation Id format: uuid additionalProperties: false StringServiceResponse: type: object properties: data: type: - string - 'null' messages: type: - array - 'null' items: $ref: '#/components/schemas/ServiceResponseMessage' additionalProperties: false ObjectServiceResponse: type: object properties: data: {} messages: type: - array - 'null' items: $ref: '#/components/schemas/ServiceResponseMessage' additionalProperties: false CreateUserPreferenceDtoServiceRequest: type: object properties: data: $ref: '#/components/schemas/CreateUserPreferenceDto' additionalProperties: false UserPreferenceDtoServiceResponse_2: type: object properties: data: allOf: - $ref: '#/components/schemas/UserPreferenceDto' messages: type: - array - 'null' items: $ref: '#/components/schemas/ServiceResponseMessage' additionalProperties: false securitySchemes: Bearer: type: apiKey description: Please insert JWT with Bearer into field name: Authorization in: header x-refined-from: - fenergo-localisationcommand-v1-0-openapi.json - fenergo-localisationquery-v1-0-openapi.json