Scout RFP (Workday Strategic Sourcing) field_options API

Use the fields API to create, update, and query the custom fields options in Workday Strategic Sourcing. Custom field options exist for single select and multiple select field types. ## Field Option Object

OpenAPI Specification

scoutrfp-field-options-api-openapi.yml Raw ↑
openapi: 3.0.2
info:
  title: Workday Strategic Sourcing attachments field_options API
  version: '1.0'
  description: '<span id="section/Authentication/api_key" data-section-id="section/Authentication/api_key"></span>

    <span id="section/Authentication/user_token" data-section-id="section/Authentication/user_token"></span>

    <span id="section/Authentication/user_email" data-section-id="section/Authentication/user_email"></span>

    '
servers:
- url: https://api.us.workdayspend.com/services/attachments/v1
  description: Production Server
- url: https://api.sandbox.us.workdayspend.com/services/attachments/v1
  description: Sandbox Server
security:
- api_key: []
  user_token: []
  user_email: []
tags:
- name: field_options
  x-displayName: Field Options
  description: 'Use the fields API to create, update, and query the custom fields options in Workday Strategic Sourcing.

    Custom field options exist for single select and multiple select field types.


    ## Field Option Object


    <SchemaDefinition schemaRef="#/components/schemas/FieldOption" showReadOnly={true} showWriteOnly={true} />

    '
paths:
  /fields/{field_id}/field_options:
    get:
      tags:
      - field_options
      description: Returns a list of field options for the specified field.
      operationId: List Field Options
      summary: List Field Options
      parameters:
      - name: field_id
        in: path
        description: Field identifier.
        required: true
        schema:
          type: integer
        example: 1
      responses:
        '200':
          description: OK
          content:
            application/vnd.api+json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/FieldOption'
              examples:
                success:
                  $ref: '#/components/examples/index_response-2'
        '401':
          description: Unauthorized
      x-codeSamples:
      - label: Curl
        source: "curl -H \"X-Api-Key: ${COMPANY_KEY}\" \\\n     -H \"X-User-Token: ${USER_TOKEN}\" \\\n     -H \"X-User-Email: ${USER_EMAIL}\" \\\n     -H \"Content-Type: application/vnd.api+json\" \\\n     \"https://api.us.workdayspend.com/services/fields/v1/fields/1/field_options\"\n"
  /field_options:
    post:
      tags:
      - field_options
      description: 'Create a field options with given parameters.

        '
      operationId: Create a Field Option
      summary: Create a Field Option
      requestBody:
        content:
          application/vnd.api+json:
            schema:
              type: object
              properties:
                data:
                  $ref: '#/components/schemas/FieldOptionCreate'
            examples:
              success:
                $ref: '#/components/examples/create_request-2'
      responses:
        '201':
          description: OK
          content:
            application/vnd.api+json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/FieldOption'
              examples:
                success:
                  $ref: '#/components/examples/create_response-2'
        '401':
          description: Unauthorized
      x-codeSamples:
      - label: Curl
        source: "curl -H \"X-Api-Key: ${COMPANY_KEY}\" \\\n     -H \"X-User-Token: ${USER_TOKEN}\" \\\n     -H \"X-User-Email: ${USER_EMAIL}\" \\\n     -H \"Content-Type: application/vnd.api+json\" \\\n     -X POST \\\n     -d '{\"data\":{\"type\":\"fields\",\"attributes\":{\"name\":\"custom_field\"}}' \\\n     \"https://api.us.workdayspend.com/services/fields/v1/field_options\"\n"
  /field_options/{id}:
    patch:
      tags:
      - field_options
      description: 'Update a field options with given parameters.

        '
      operationId: Update a Field Option
      summary: Update a Field Option
      parameters:
      - name: id
        in: path
        description: Unique Field Option identifier.
        required: true
        schema:
          type: integer
        example: 1
      requestBody:
        content:
          application/vnd.api+json:
            schema:
              type: object
              properties:
                data:
                  $ref: '#/components/schemas/FieldOptionUpdate'
            examples:
              success:
                $ref: '#/components/examples/update_request-2'
      responses:
        '200':
          description: OK
          content:
            application/vnd.api+json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/FieldOption'
              examples:
                success:
                  $ref: '#/components/examples/update_response-2'
        '401':
          description: Unauthorized
      x-codeSamples:
      - label: Curl
        source: "curl -H \"X-Api-Key: ${COMPANY_KEY}\" \\\n     -H \"X-User-Token: ${USER_TOKEN}\" \\\n     -H \"X-User-Email: ${USER_EMAIL}\" \\\n     -H \"Content-Type: application/vnd.api+json\" \\\n     -X PATCH \\\n     -d '{\"data\":{\"type\":\"fields\",\"id\":\"1\",\"attributes\":{\"label\":\"custom_field\"}}' \\\n     \"https://api.us.workdayspend.com/services/fields/v1/field_options/1\"\n"
    delete:
      tags:
      - field_options
      description: 'Deletes a field option. You need to supply the unique field option

        identifier that was returned upon field creation.

        '
      operationId: Delete a Field Option
      summary: Delete a Field Option
      parameters:
      - name: id
        in: path
        description: Unique Field Option identifier.
        required: true
        schema:
          type: integer
        example: 1
      responses:
        '204':
          description: OK
        '401':
          description: Unauthorized
        '404':
          description: Not Found
      x-codeSamples:
      - label: Curl
        source: "curl -H \"X-Api-Key: ${COMPANY_KEY}\" \\\n     -H \"X-User-Token: ${USER_TOKEN}\" \\\n     -H \"X-User-Email: ${USER_EMAIL}\" \\\n     -H \"Content-Type: application/vnd.api+json\" \\\n     -X DELETE \\\n     \"https://api.us.workdayspend.com/services/fields/v1/field_options/1\"\n"
components:
  schemas:
    FieldType:
      type: string
      description: Object type, should always be `fields`.
      example: fields
    FieldOptionType:
      type: string
      description: Object type, should always be `fields`.
      example: fields
    FieldOption:
      allOf:
      - $ref: '#/components/schemas/FieldOptionBase'
      - type: object
        properties:
          attributes:
            $ref: '#/components/schemas/FieldOptionAttributes'
    FieldOptionCreate:
      type: object
      required:
      - type
      properties:
        type:
          $ref: '#/components/schemas/FieldOptionType'
        attributes:
          $ref: '#/components/schemas/FieldOptionAttributes'
        relationships:
          $ref: '#/components/schemas/FieldOptionRelationship'
    FieldOptionUpdate:
      type: object
      required:
      - type
      - id
      properties:
        type:
          $ref: '#/components/schemas/FieldOptionType'
        id:
          $ref: '#/components/schemas/FieldOptionId'
        attributes:
          $ref: '#/components/schemas/FieldOptionAttributes'
    FieldOptionRelationship:
      type: object
      description: Field option relationship.
      required:
      - field
      properties:
        field:
          type: object
          properties:
            data:
              $ref: '#/components/schemas/FieldBase'
    FieldOptionId:
      type: integer
      description: Field identifier string.
      example: 1
    FieldId:
      type: integer
      description: Field identifier string.
      example: 1
    FieldOptionAttributes:
      type: object
      description: Field attributes.
      required:
      - name
      properties:
        label:
          type: string
          maxLength: 255
          description: Field name.
        position:
          type: integer
          description: Field order position on the UI.
          readOnly: true
    FieldBase:
      title: Field
      type: object
      required:
      - type
      - id
      properties:
        type:
          $ref: '#/components/schemas/FieldType'
        id:
          $ref: '#/components/schemas/FieldId'
    FieldOptionBase:
      title: Field
      type: object
      required:
      - type
      - id
      properties:
        type:
          $ref: '#/components/schemas/FieldOptionType'
        id:
          $ref: '#/components/schemas/FieldOptionId'
  examples:
    create_request-2:
      value:
        data:
          type: field_options
          attributes:
            label: Field Option One
          relationships:
            field:
              data:
                type: fields
                id: '1'
    update_request-2:
      value:
        data:
          id: '1'
          type: field_options
          attributes:
            label: Updated Field Option
    update_response-2:
      value:
        data:
          id: '1'
          type: field_options
          attributes:
            label: Updated Field Option
            position: 1
    index_response-2:
      value:
        data:
        - id: '1'
          type: field_options
          attributes:
            label: Option One
            position: 1
        - id: '2'
          type: field_options
          attributes:
            label: Option Two
            position: 2
        links: {}
    create_response-2:
      value:
        data:
          id: '1'
          type: field_options
          attributes:
            label: Field Option One
            position: null
  securitySchemes:
    api_key:
      type: apiKey
      name: X-Api-Key
      in: header
      description: Company API key.
    user_token:
      type: apiKey
      name: X-User-Token
      in: header
      description: User token.
    user_email:
      type: apiKey
      name: X-User-Email
      in: header
      description: User email.
x-tagGroups:
- name: Getting Started
  tags:
  - support
  - servers
  - api_specification
  - authentication
  - rate_limiting
- name: Attachments
  tags:
  - attachments