openapi: 3.0.3 info: title: Argilla v1 Authentication questions API description: Argilla Server API v1 version: 2.8.0 license: name: Apache 2.0 url: https://www.apache.org/licenses/LICENSE-2.0 contact: email: contact@argilla.io url: https://argilla.io servers: - url: https://argilla.io/api/v1 description: Argilla REST API v1 tags: - name: questions paths: /questions/{question_id}: patch: tags: - questions summary: Update Question operationId: update_question_questions__question_id__patch security: - APIKeyHeader: [] - HTTPBearer: [] parameters: - name: question_id in: path required: true schema: type: string format: uuid title: Question Id requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/QuestionUpdate' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/Question' '400': content: application/json: example: detail: code: argilla.api.errors::MissingDatasetRecordsError params: extra: error parameters description: Bad Request '404': content: application/json: example: detail: code: argilla.api.errors::EntityNotFoundError params: extra: error parameters description: Not Found '403': content: application/json: example: detail: code: argilla.api.errors::ForbiddenOperationError params: extra: error parameters description: Forbidden '409': content: application/json: example: detail: code: argilla.api.errors::EntityAlreadyExistsError params: extra: error parameters description: Conflict '422': content: application/json: example: detail: code: argilla.api.errors::ValidationError params: extra: error parameters description: Unprocessable Content '500': content: application/json: example: detail: code: builtins.TypeError description: Internal Server Error delete: tags: - questions summary: Delete Question operationId: delete_question_questions__question_id__delete security: - APIKeyHeader: [] - HTTPBearer: [] parameters: - name: question_id in: path required: true schema: type: string format: uuid title: Question Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/Question' '400': content: application/json: example: detail: code: argilla.api.errors::MissingDatasetRecordsError params: extra: error parameters description: Bad Request '404': content: application/json: example: detail: code: argilla.api.errors::EntityNotFoundError params: extra: error parameters description: Not Found '403': content: application/json: example: detail: code: argilla.api.errors::ForbiddenOperationError params: extra: error parameters description: Forbidden '409': content: application/json: example: detail: code: argilla.api.errors::EntityAlreadyExistsError params: extra: error parameters description: Conflict '422': content: application/json: example: detail: code: argilla.api.errors::ValidationError params: extra: error parameters description: Unprocessable Content '500': content: application/json: example: detail: code: builtins.TypeError description: Internal Server Error components: schemas: OptionsOrder: type: string enum: - natural - suggestion title: OptionsOrder LabelSelectionSettingsUpdate: properties: type: type: string enum: - label_selection const: label_selection title: Type visible_options: title: Visible Options type: integer minimum: 3.0 nullable: true options: title: Options items: $ref: '#/components/schemas/OptionSettings' type: array maxItems: 500 minItems: 2 nullable: true type: object required: - type title: LabelSelectionSettingsUpdate Question: properties: id: type: string format: uuid title: Id name: type: string title: Name title: type: string title: Title description: title: Description type: string nullable: true required: type: boolean title: Required settings: oneOf: - $ref: '#/components/schemas/TextQuestionSettings' - $ref: '#/components/schemas/RatingQuestionSettings' - $ref: '#/components/schemas/LabelSelectionQuestionSettings' - $ref: '#/components/schemas/MultiLabelSelectionQuestionSettings' - $ref: '#/components/schemas/RankingQuestionSettings' - $ref: '#/components/schemas/SpanQuestionSettings' title: Settings discriminator: propertyName: type mapping: label_selection: '#/components/schemas/LabelSelectionQuestionSettings' multi_label_selection: '#/components/schemas/MultiLabelSelectionQuestionSettings' ranking: '#/components/schemas/RankingQuestionSettings' rating: '#/components/schemas/RatingQuestionSettings' span: '#/components/schemas/SpanQuestionSettings' text: '#/components/schemas/TextQuestionSettings' dataset_id: type: string format: uuid title: Dataset Id inserted_at: type: string format: date-time title: Inserted At updated_at: type: string format: date-time title: Updated At type: object required: - id - name - title - required - settings - dataset_id - inserted_at - updated_at title: Question RankingQuestionSettings: properties: type: type: string enum: - ranking const: ranking title: Type options: items: $ref: '#/components/schemas/OptionSettings' type: array title: Options type: object required: - type - options title: RankingQuestionSettings RatingQuestionSettings: properties: type: type: string enum: - rating const: rating title: Type options: items: $ref: '#/components/schemas/RatingQuestionSettingsOption' type: array title: Options type: object required: - type - options title: RatingQuestionSettings RatingQuestionSettingsUpdate: properties: type: type: string enum: - rating const: rating title: Type type: object required: - type title: RatingQuestionSettingsUpdate TextQuestionSettingsUpdate: properties: type: type: string enum: - text const: text title: Type use_markdown: title: Use Markdown type: boolean nullable: true type: object required: - type title: TextQuestionSettingsUpdate RatingQuestionSettingsOption: properties: value: type: integer title: Value type: object required: - value title: RatingQuestionSettingsOption MultiLabelSelectionQuestionSettings: properties: type: type: string enum: - multi_label_selection const: multi_label_selection title: Type options: items: $ref: '#/components/schemas/OptionSettings' type: array title: Options visible_options: title: Visible Options type: integer nullable: true options_order: $ref: '#/components/schemas/OptionsOrder' default: natural type: object required: - type - options title: MultiLabelSelectionQuestionSettings SpanQuestionSettings: properties: type: type: string enum: - span const: span title: Type field: type: string title: Field options: items: $ref: '#/components/schemas/OptionSettings' type: array title: Options visible_options: title: Visible Options type: integer nullable: true allow_overlapping: type: boolean title: Allow Overlapping description: Allow spans overlapping default: false allow_character_annotation: type: boolean title: Allow Character Annotation description: Allow character-level annotation default: true type: object required: - type - field - options title: SpanQuestionSettings LabelSelectionQuestionSettings: properties: type: type: string enum: - label_selection const: label_selection title: Type options: items: $ref: '#/components/schemas/OptionSettings' type: array title: Options visible_options: title: Visible Options type: integer nullable: true type: object required: - type - options title: LabelSelectionQuestionSettings SpanQuestionSettingsUpdate: properties: type: type: string enum: - span const: span title: Type options: title: Options items: $ref: '#/components/schemas/OptionSettings' type: array maxItems: 500 minItems: 1 nullable: true visible_options: title: Visible Options type: integer minimum: 3.0 nullable: true allow_overlapping: title: Allow Overlapping type: boolean nullable: true type: object required: - type title: SpanQuestionSettingsUpdate QuestionUpdate: properties: title: title: Title type: string maxLength: 500 minLength: 1 description: The title of the question nullable: true description: title: Description type: string maxLength: 1000 minLength: 1 description: The description of the question nullable: true settings: title: Settings oneOf: - $ref: '#/components/schemas/TextQuestionSettingsUpdate' - $ref: '#/components/schemas/RatingQuestionSettingsUpdate' - $ref: '#/components/schemas/LabelSelectionSettingsUpdate' - $ref: '#/components/schemas/MultiLabelSelectionQuestionSettingsUpdate' - $ref: '#/components/schemas/RankingQuestionSettingsUpdate' - $ref: '#/components/schemas/SpanQuestionSettingsUpdate' discriminator: propertyName: type mapping: label_selection: '#/components/schemas/LabelSelectionSettingsUpdate' multi_label_selection: '#/components/schemas/MultiLabelSelectionQuestionSettingsUpdate' ranking: '#/components/schemas/RankingQuestionSettingsUpdate' rating: '#/components/schemas/RatingQuestionSettingsUpdate' span: '#/components/schemas/SpanQuestionSettingsUpdate' text: '#/components/schemas/TextQuestionSettingsUpdate' nullable: true type: object title: QuestionUpdate TextQuestionSettings: properties: type: type: string enum: - text const: text title: Type use_markdown: type: boolean title: Use Markdown default: false type: object required: - type title: TextQuestionSettings RankingQuestionSettingsUpdate: properties: type: type: string enum: - ranking const: ranking title: Type type: object required: - type title: RankingQuestionSettingsUpdate MultiLabelSelectionQuestionSettingsUpdate: properties: type: type: string enum: - multi_label_selection const: multi_label_selection title: Type visible_options: title: Visible Options type: integer minimum: 3.0 nullable: true options: title: Options items: $ref: '#/components/schemas/OptionSettings' type: array maxItems: 500 minItems: 2 nullable: true options_order: $ref: '#/components/schemas/OptionsOrder' nullable: true type: object required: - type title: MultiLabelSelectionQuestionSettingsUpdate OptionSettings: properties: value: type: string title: Value text: type: string title: Text description: title: Description type: string nullable: true type: object required: - value - text title: OptionSettings securitySchemes: APIKeyHeader: type: apiKey in: header name: X-Argilla-Api-Key HTTPBearer: type: http scheme: bearer