openapi: 3.2.0 info: title: AWX Schedules API version: v2 description: AWX API Documentation contact: email: ansible-community@redhat.com license: name: Apache License tags: - name: Schedules paths: /api/v2/schedules/: get: operationId: schedules_list parameters: - in: query name: order schema: type: string description: Order results by field name. Prefix with '-' for descending order. Supports comma-separated values for multiple fields. - in: query name: order_by schema: type: string description: Order results by field name. Prefix with '-' for descending order. Supports comma-separated values for multiple fields. - name: page required: false in: query description: A page number within the paginated result set. schema: type: integer - name: page_size required: false in: query description: Number of results to return per page. schema: type: integer - in: query name: role_level schema: type: string description: Filter by role level for RBAC - name: search required: false in: query description: A search term. schema: type: string - in: query name: type schema: type: string description: Filter by object type. Supports comma-separated values for multiple types. tags: - Schedules responses: '200': content: application/json: schema: $ref: '#/components/schemas/PaginatedScheduleList' description: '' x-ai-description: List schedules summary: Schedules list x-summary-source: derived post: operationId: schedules_create tags: - Schedules requestBody: content: application/json: schema: $ref: '#/components/schemas/ScheduleRequest' required: true responses: '201': content: application/json: schema: $ref: '#/components/schemas/Schedule' description: '' x-ai-description: Create a schedule for recurring automated execution of a job template, workflow job template, project sync, inventory sync or management job. summary: Schedules create x-summary-source: derived /api/v2/schedules/{id}/: get: operationId: schedules_retrieve parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true tags: - Schedules responses: '200': content: application/json: schema: $ref: '#/components/schemas/Schedule' description: '' x-ai-description: Retrieve a schedule summary: Schedules retrieve x-summary-source: derived put: operationId: schedules_update parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true tags: - Schedules requestBody: content: application/json: schema: $ref: '#/components/schemas/ScheduleRequest' required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/Schedule' description: '' x-ai-description: Update a schedule summary: Schedules update x-summary-source: derived patch: operationId: schedules_partial_update parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true tags: - Schedules requestBody: content: application/json: schema: $ref: '#/components/schemas/PatchedScheduleRequest' responses: '200': content: application/json: schema: $ref: '#/components/schemas/Schedule' description: '' x-ai-description: Update a schedule summary: Schedules partial update x-summary-source: derived delete: operationId: schedules_destroy parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true tags: - Schedules responses: '204': description: No response body x-ai-description: Delete a schedule summary: Schedules destroy x-summary-source: derived /api/v2/schedules/{id}/credentials/: get: operationId: schedules_credentials_list description: Derived version of SubListCreateAttachDetachAPIView that prohibits creation parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true - in: query name: order schema: type: string description: Order results by field name. Prefix with '-' for descending order. Supports comma-separated values for multiple fields. - in: query name: order_by schema: type: string description: Order results by field name. Prefix with '-' for descending order. Supports comma-separated values for multiple fields. - name: page required: false in: query description: A page number within the paginated result set. schema: type: integer - name: page_size required: false in: query description: Number of results to return per page. schema: type: integer - in: query name: role_level schema: type: string description: Filter by role level for RBAC - name: search required: false in: query description: A search term. schema: type: string - in: query name: type schema: type: string description: Filter by object type. Supports comma-separated values for multiple types. tags: - Schedules responses: '200': content: application/json: schema: $ref: '#/components/schemas/PaginatedCredentialList' description: '' x-ai-description: List credentials of a schedule summary: Schedules credentials list x-summary-source: derived post: operationId: schedules_credentials_create description: Derived version of SubListCreateAttachDetachAPIView that prohibits creation parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true tags: - Schedules requestBody: content: application/json: schema: $ref: '#/components/schemas/CredentialRequest' required: true responses: '201': content: application/json: schema: $ref: '#/components/schemas/Credential' description: '' x-ai-description: Create a credential of a schedule summary: Schedules credentials create x-summary-source: derived /api/v2/schedules/{id}/instance_groups/: get: operationId: schedules_instance_groups_list description: Derived version of SubListCreateAttachDetachAPIView that prohibits creation parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true - in: query name: order schema: type: string description: Order results by field name. Prefix with '-' for descending order. Supports comma-separated values for multiple fields. - in: query name: order_by schema: type: string description: Order results by field name. Prefix with '-' for descending order. Supports comma-separated values for multiple fields. - name: page required: false in: query description: A page number within the paginated result set. schema: type: integer - name: page_size required: false in: query description: Number of results to return per page. schema: type: integer - in: query name: role_level schema: type: string description: Filter by role level for RBAC - name: search required: false in: query description: A search term. schema: type: string - in: query name: type schema: type: string description: Filter by object type. Supports comma-separated values for multiple types. tags: - Schedules responses: '200': content: application/json: schema: $ref: '#/components/schemas/PaginatedInstanceGroupList' description: '' x-ai-description: List instance groups of a schedule summary: Schedules instance groups list x-summary-source: derived post: operationId: schedules_instance_groups_create description: Derived version of SubListCreateAttachDetachAPIView that prohibits creation parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true tags: - Schedules requestBody: content: application/json: schema: $ref: '#/components/schemas/InstanceGroupRequest' required: true responses: '201': content: application/json: schema: $ref: '#/components/schemas/InstanceGroup' description: '' x-ai-description: Create an instance group of a schedule summary: Schedules instance groups create x-summary-source: derived /api/v2/schedules/{id}/jobs/: get: operationId: schedules_jobs_list parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true - in: query name: order schema: type: string description: Order results by field name. Prefix with '-' for descending order. Supports comma-separated values for multiple fields. - in: query name: order_by schema: type: string description: Order results by field name. Prefix with '-' for descending order. Supports comma-separated values for multiple fields. - name: page required: false in: query description: A page number within the paginated result set. schema: type: integer - name: page_size required: false in: query description: Number of results to return per page. schema: type: integer - in: query name: role_level schema: type: string description: Filter by role level for RBAC - name: search required: false in: query description: A search term. schema: type: string - in: query name: type schema: type: string description: Filter by object type. Supports comma-separated values for multiple types. tags: - Schedules responses: '200': content: application/json: schema: $ref: '#/components/schemas/PaginatedUnifiedJobListList' description: '' x-ai-description: List jobs created by a schedule summary: Schedules jobs list x-summary-source: derived /api/v2/schedules/{id}/labels/: get: operationId: schedules_labels_list description: 'For related labels lists like /api/v2/inventories/N/labels/ We want want the last instance to be deleted from the database when the last disassociate happens. Subclasses need to define parent_model' parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true - in: query name: order schema: type: string description: Order results by field name. Prefix with '-' for descending order. Supports comma-separated values for multiple fields. - in: query name: order_by schema: type: string description: Order results by field name. Prefix with '-' for descending order. Supports comma-separated values for multiple fields. - name: page required: false in: query description: A page number within the paginated result set. schema: type: integer - name: page_size required: false in: query description: Number of results to return per page. schema: type: integer - in: query name: role_level schema: type: string description: Filter by role level for RBAC - name: search required: false in: query description: A search term. schema: type: string - in: query name: type schema: type: string description: Filter by object type. Supports comma-separated values for multiple types. tags: - Schedules responses: '200': content: application/json: schema: $ref: '#/components/schemas/PaginatedLabelList' description: '' x-ai-description: List labels of a schedule summary: Schedules labels list x-summary-source: derived post: operationId: schedules_labels_create description: 'For related labels lists like /api/v2/inventories/N/labels/ We want want the last instance to be deleted from the database when the last disassociate happens. Subclasses need to define parent_model' parameters: - in: path name: id schema: type: string pattern: ^[0-9]+$ required: true tags: - Schedules requestBody: content: application/json: schema: $ref: '#/components/schemas/LabelRequest' required: true responses: '201': content: application/json: schema: $ref: '#/components/schemas/Label' description: '' x-ai-description: Create or attach a label to a resource summary: Schedules labels create x-summary-source: derived /api/v2/schedules/preview/: post: operationId: schedules_preview_create tags: - Schedules requestBody: content: application/json: schema: $ref: '#/components/schemas/SchedulePreviewRequest' required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/SchedulePreview' description: '' x-ai-description: Preview schedule recurrence rule occurrences summary: Schedules preview create x-summary-source: derived /api/v2/schedules/zoneinfo/: get: operationId: schedules_zoneinfo_retrieve tags: - Schedules responses: '200': description: No response body x-ai-description: Get timezone information for schedules summary: Schedules zoneinfo retrieve x-summary-source: derived components: schemas: PaginatedCredentialList: type: object required: - count - results properties: count: type: integer example: 123 next: type: - string - 'null' format: uri example: http://api.example.org/accounts/?page=4 previous: type: - string - 'null' format: uri example: http://api.example.org/accounts/?page=2 results: type: array items: $ref: '#/components/schemas/Credential' InstanceGroup: type: object properties: id: type: integer readOnly: true type: type: string readOnly: true url: type: string readOnly: true related: type: string readOnly: true name: type: - string - 'null' maxLength: 250 created: type: string readOnly: true modified: type: string readOnly: true capacity: type: string readOnly: true consumed_capacity: type: string readOnly: true percent_capacity_remaining: type: string readOnly: true jobs_running: type: string readOnly: true max_concurrent_jobs: type: integer minimum: 0 default: 0 description: Maximum number of concurrent jobs to run on a group. When set to zero, no maximum is enforced. max_forks: type: integer minimum: 0 default: 0 description: Maximum number of forks to execute concurrently on a group. When set to zero, no maximum is enforced. jobs_total: type: integer readOnly: true description: Count of all jobs that target this instance group instances: type: string readOnly: true is_container_group: type: boolean description: Indicates whether instances in this group are containerized.Containerized groups have a designated Openshift or Kubernetes cluster. credential: type: - integer - 'null' policy_instance_percentage: type: integer maximum: 100 minimum: 0 default: 0 description: Minimum percentage of all instances that will be automatically assigned to this group when new instances come online. policy_instance_minimum: type: integer minimum: 0 default: 0 description: Static minimum number of Instances that will be automatically assign to this group when new instances come online. policy_instance_list: type: array items: type: string description: List of exact-match Instances that will be assigned to this group pod_spec_override: type: - string - 'null' default: '' summary_fields: type: string readOnly: true required: - name SchedulePreview: type: object properties: rrule: type: - string - 'null' description: A value representing the schedules iCal recurrence rule. required: - rrule PaginatedInstanceGroupList: type: object required: - count - results properties: count: type: integer example: 123 next: type: - string - 'null' format: uri example: http://api.example.org/accounts/?page=4 previous: type: - string - 'null' format: uri example: http://api.example.org/accounts/?page=2 results: type: array items: $ref: '#/components/schemas/InstanceGroup' ScheduleRequest: type: object properties: rrule: type: - string - 'null' minLength: 1 description: A value representing the schedules iCal recurrence rule. name: type: - string - 'null' minLength: 1 maxLength: 512 description: type: - string - 'null' default: '' extra_data: default: {} inventory: type: - integer - 'null' description: Inventory applied as a prompt, assuming job template prompts for inventory scm_branch: type: - string - 'null' job_type: enum: - run - check - '' - null type: - string - 'null' description: '* `run` - Run * `check` - Check' x-spec-enum-id: 726608a431c1f104 job_tags: type: - string - 'null' skip_tags: type: - string - 'null' limit: type: - string - 'null' diff_mode: type: - boolean - 'null' verbosity: enum: - 0 - 1 - 2 - 3 - 4 - 5 - null type: - integer - 'null' description: '* `0` - 0 (Normal) * `1` - 1 (Verbose) * `2` - 2 (More Verbose) * `3` - 3 (Debug) * `4` - 4 (Connection Debug) * `5` - 5 (WinRM Debug)' x-spec-enum-id: 8cfb81af905b865a execution_environment: type: - integer - 'null' description: The container image to be used for execution. forks: type: - integer - 'null' minimum: 0 job_slice_count: type: - integer - 'null' minimum: 0 timeout: type: - integer - 'null' unified_job_template: type: integer enabled: type: - boolean - 'null' default: true description: Enables processing of this schedule. required: - name - rrule - unified_job_template UnifiedJobList: type: object properties: id: type: integer readOnly: true type: type: string readOnly: true url: type: string readOnly: true related: type: string readOnly: true summary_fields: type: string readOnly: true created: type: string readOnly: true modified: type: string readOnly: true name: type: - string - 'null' maxLength: 512 description: type: - string - 'null' default: '' unified_job_template: type: - integer - 'null' readOnly: true launch_type: enum: - manual - relaunch - callback - scheduled - dependency - workflow - webhook - sync - scm type: string description: '* `manual` - Manual * `relaunch` - Relaunch * `callback` - Callback * `scheduled` - Scheduled * `dependency` - Dependency * `workflow` - Workflow * `webhook` - Webhook * `sync` - Sync * `scm` - SCM Update' x-spec-enum-id: e5bed25c2e652da3 readOnly: true status: enum: - new - pending - waiting - running - successful - failed - error - canceled type: string description: '* `new` - New * `pending` - Pending * `waiting` - Waiting * `running` - Running * `successful` - Successful * `failed` - Failed * `error` - Error * `canceled` - Canceled' x-spec-enum-id: 6021859c28387823 readOnly: true execution_environment: type: - integer - 'null' description: The container image to be used for execution. failed: type: boolean readOnly: true started: type: - string - 'null' format: date-time readOnly: true description: The date and time the job was queued for starting. finished: type: - string - 'null' format: date-time readOnly: true description: The date and time the job finished execution. canceled_on: type: - string - 'null' format: date-time readOnly: true description: The date and time when the cancel request was sent. elapsed: type: string format: decimal pattern: ^-?\d{0,9}(?:\.\d{0,3})?$ readOnly: true description: Elapsed time in seconds that the job ran. job_explanation: type: string readOnly: true description: A status field to indicate the state of the job if it wasn't able to run and capture stdout execution_node: type: string readOnly: true description: The node the job executed on. controller_node: type: string readOnly: true description: The instance that managed the execution environment. launched_by: type: string readOnly: true work_unit_id: type: - string - 'null' readOnly: true description: The Receptor work unit ID associated with this job. required: - name SchedulePreviewRequest: type: object properties: rrule: type: - string - 'null' minLength: 1 description: A value representing the schedules iCal recurrence rule. required: - rrule PaginatedUnifiedJobListList: type: object required: - count - results properties: count: type: integer example: 123 next: type: - string - 'null' format: uri example: http://api.example.org/accounts/?page=4 previous: type: - string - 'null' format: uri example: http://api.example.org/accounts/?page=2 results: type: array items: $ref: '#/components/schemas/UnifiedJobList' Credential: type: object properties: id: type: integer readOnly: true type: type: string readOnly: true url: type: string readOnly: true related: type: string readOnly: true summary_fields: type: string readOnly: true created: type: string readOnly: true modified: type: string readOnly: true name: type: - string - 'null' maxLength: 512 description: type: - string - 'null' default: '' organization: type: - integer - 'null' credential_type: type: integer description: Specify the type of credential you want to create. Refer to the documentation for details on each type. managed: type: boolean readOnly: true inputs: default: {} description: Enter inputs using either JSON or YAML syntax. Refer to the documentation for example syntax. kind: type: string readOnly: true cloud: type: string readOnly: true kubernetes: type: string readOnly: true required: - credential_type - name Label: type: object properties: id: type: integer readOnly: true type: type: string readOnly: true url: type: string readOnly: true related: type: string readOnly: true summary_fields: type: string readOnly: true created: type: string readOnly: true modified: type: string readOnly: true name: type: - string - 'null' maxLength: 512 organization: type: integer description: Organization this label belongs to. required: - name - organization InstanceGroupRequest: type: object properties: name: type: - string - 'null' minLength: 1 maxLength: 250 max_concurrent_jobs: type: integer minimum: 0 default: 0 description: Maximum number of concurrent jobs to run on a group. When set to zero, no maximum is enforced. max_forks: type: integer minimum: 0 default: 0 description: Maximum number of forks to execute concurrently on a group. When set to zero, no maximum is enforced. is_container_group: type: boolean description: Indicates whether instances in this group are containerized.Containerized groups have a designated Openshift or Kubernetes cluster. credential: type: - integer - 'null' policy_instance_percentage: type: integer maximum: 100 minimum: 0 default: 0 description: Minimum percentage of all instances that will be automatically assigned to this group when new instances come online. policy_instance_minimum: type: integer minimum: 0 default: 0 description: Static minimum number of Instances that will be automatically assign to this group when new instances come online. policy_instance_list: type: array items: type: string minLength: 1 description: List of exact-match Instances that will be assigned to this group pod_spec_override: type: - string - 'null' default: '' required: - name PatchedScheduleRequest: type: object properties: rrule: type: - string - 'null' minLength: 1 description: A value representing the schedules iCal recurrence rule. name: type: - string - 'null' minLength: 1 maxLength: 512 description: type: - string - 'null' default: '' extra_data: default: {} inventory: type: - integer - 'null' description: Inventory applied as a prompt, assuming job template prompts for inventory scm_branch: type: - string - 'null' job_type: enum: - run - check - '' - null type: - string - 'null' description: '* `run` - Run * `check` - Check' x-spec-enum-id: 726608a431c1f104 job_tags: type: - string - 'null' skip_tags: type: - string - 'null' limit: type: - string - 'null' diff_mode: type: - boolean - 'null' verbosity: enum: - 0 - 1 - 2 - 3 - 4 - 5 - null type: - integer - 'null' description: '* `0` - 0 (Normal) * `1` - 1 (Verbose) * `2` - 2 (More Verbose) * `3` - 3 (Debug) * `4` - 4 (Connection Debug) * `5` - 5 (WinRM Debug)' x-spec-enum-id: 8cfb81af905b865a execution_environment: type: - integer - 'null' description: The container image to be used for execution. forks: type: - integer - 'null' minimum: 0 job_slice_count: type: - integer - 'null' minimum: 0 timeout: type: - integer - 'null' unified_job_template: type: integer enabled: type: - boolean - 'null' default: true description: Enables processing of this schedule. CredentialRequest: type: object properties: name: type: - string - 'null' minLength: 1 maxLength: 512 description: type: - string - 'null' default: '' organization: type: - integer - 'null' credential_type: type: integer description: Specify the type of credential you want to create. Refer to the documentation for details on each type. inputs: default: {} description: Enter inputs using either JSON or YAML syntax. Refer to the documentation for example syntax. required: - credential_type - name PaginatedLabelList: type: object required: - count - results properties: count: type: integer example: 123 next: type: - string - 'null' format: uri example: http://api.example.org/accounts/?page=4 previous: type: - string - 'null' format: uri example: http://api.example.org/accounts/?page=2 results: type: array items: $ref: '#/components/schemas/Label' Schedule: type: object properties: rrule: type: - string - 'null' description: A value representing the schedules iCal recurrence rule. id: type: integer readOnly: true type: type: string readOnly: true url: type: string readOnly: true related: type: string readOnly: true summary_fields: type: string readOnly: true created: type: string readOnly: true modified: type: string readOnly: true name: type: - string - 'null' maxLength: 512 description: type: - string - 'null' default: '' extra_data: default: {} inventory: type: - integer - 'null' description: Inventory applied as a prompt, assuming job template prompts for inventory scm_branch: type: - string - 'null' job_type: enum: - run - check - '' - null type: - string - 'null' description: '* `run` - Run * `check` - Check' x-spec-enum-id: 726608a431c1f104 job_tags: type: - string - 'null' skip_tags: type: - string - 'null' limit: type: - string - 'null' diff_mode: type: - boolean - 'null' verbosity: enum: - 0 - 1 - 2 - 3 - 4 - 5 - null type: - integer - 'null' description: '* `0` - 0 (Normal) * `1` - 1 (Verbose) * `2` - 2 (More Verbose) * `3` - 3 (Debug) * `4` - 4 (Connection Debug) * `5` - 5 (WinRM Debug)' x-spec-enum-id: 8cfb81af905b865a execution_environment: type: - integer - 'null' description: The container image to be used for execution. forks: type: - integer - 'null' minimum: 0 job_slice_count: type: - integer - 'null' minimum: 0 timeout: type: - integer - 'null' unified_job_template: type: integer enabled: type: - boolean - 'null' default: true description: Enables processing of this schedule. dtstart: type: - string - 'null' format: date-time readOnly: true description: The first occurrence of the schedule occurs on or after this time. dtend: type: - string - 'null' format: date-time readOnly: true description: The last occurrence of the schedule occurs before this time, aftewards the schedule expires. next_run: type: - string - 'null' format: date-time readOnly: true description: The next time that the scheduled action will run. timezone: type: string readOnly: true description: The timezone this schedule runs in. This field is extracted from the RRULE. If the timezone in the RRULE is a link to another timezone, the link will be reflected in this field. until: type: string readOnly: true description: The date this schedule will end. This field is computed from the RRULE. If the schedule does not end an empty string will be returned required: - name - rrule - unified_job_template LabelRequest: type: object properties: name: type: - string - 'null' minLength: 1 maxLength: 512 organization: type: integer description: Organization this label belongs to. required: - name - organization PaginatedScheduleList: type: object required: - count - results properties: count: type: integer example: 123 next: type: - string - 'null' format: uri example: http://api.example.org/accounts/?page=4 previous: type: - string - 'null' format: uri example: http://api.example.org/accounts/?page=2 results: type: array items: $ref: '#/components/schemas/Schedule'