openapi: 3.2.0 info: title: Event Driven Ansible Activations API version: 0.2.0 servers: - url: /api/eda/v1 tags: - name: Activations paths: /activations/: get: operationId: activations_list description: List Activations parameters: - in: query name: decision_environment_id schema: type: number description: Filter by Decision Environment ID. - in: query name: name schema: type: string description: Filter by activation name. - 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: project_id schema: type: number description: Filter by project id - in: query name: status schema: type: string description: Filter by activation status. tags: - Activations security: - EDAJWTAuthentication: [] responses: '200': content: application/json: schema: $ref: '#/components/schemas/PaginatedActivationListList' description: Return a list of Activations. x-ai-description: List activations. Returns activation records. Supports filtering and pagination. summary: Activations list x-summary-source: derived post: operationId: activations_create tags: - Activations requestBody: content: application/json: schema: $ref: '#/components/schemas/ActivationCreate' application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/ActivationCreate' multipart/form-data: schema: $ref: '#/components/schemas/ActivationCreate' required: true security: - EDAJWTAuthentication: [] responses: '201': content: application/json: schema: $ref: '#/components/schemas/ActivationRead' description: '' '400': description: Invalid data to create activation. '503': description: Dependent service issues x-ai-description: Create an activation. Returns the created activation. summary: Activations create x-summary-source: derived /activations/{id}/instances/: get: operationId: activations_instances_list description: List all instances for the Activation parameters: - in: path name: id schema: type: integer description: A unique integer value identifying this rulebook. required: true - in: query name: name schema: type: string description: Filter by activation instance name. - 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: status schema: type: string description: Filter by activation instance status. tags: - Activations security: - EDAJWTAuthentication: [] responses: '200': content: application/json: schema: $ref: '#/components/schemas/PaginatedActivationInstanceList' description: '' summary: Activations instances list x-summary-source: derived /activations/{id}/: get: operationId: activations_retrieve parameters: - in: path name: id schema: type: integer description: A unique integer value identifying this activation. required: true tags: - Activations security: - EDAJWTAuthentication: [] responses: '200': content: application/json: schema: $ref: '#/components/schemas/ActivationRead' description: '' summary: Activations retrieve x-summary-source: derived patch: operationId: activations_partial_update parameters: - in: path name: id schema: type: integer description: A unique integer value identifying this activation. required: true tags: - Activations requestBody: content: application/json: schema: $ref: '#/components/schemas/PatchedActivationUpdate' application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/PatchedActivationUpdate' multipart/form-data: schema: $ref: '#/components/schemas/PatchedActivationUpdate' security: - EDAJWTAuthentication: [] responses: '200': content: application/json: schema: $ref: '#/components/schemas/ActivationRead' description: '' '400': description: Invalid data to update activation. '409': description: The activation is not allowed to be updated. x-ai-description: Update an activation by ID. Returns the updated activation. summary: Activations partial update x-summary-source: derived delete: operationId: activations_destroy description: Delete an existing Activation parameters: - in: query name: force schema: type: boolean description: Force delete after worker node offline - in: path name: id schema: type: integer description: A unique integer value identifying this activation. required: true tags: - Activations security: - EDAJWTAuthentication: [] responses: '204': description: The Activation has been deleted. '409': description: Activation blocked while Workers offline. summary: Activations destroy x-summary-source: derived /activations/{id}/copy/: post: operationId: activations_copy_create description: Copy an activation. parameters: - in: path name: id schema: type: integer description: A unique integer value identifying this activation. required: true tags: - Activations requestBody: content: application/json: schema: $ref: '#/components/schemas/ActivationCopy' application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/ActivationCopy' multipart/form-data: schema: $ref: '#/components/schemas/ActivationCopy' required: true security: - EDAJWTAuthentication: [] responses: '201': content: application/json: schema: $ref: '#/components/schemas/ActivationRead' description: Return the copied activation. '404': description: Activation not found. summary: Activations copy create x-summary-source: derived /activations/{id}/disable/: post: operationId: activations_disable_create description: Disable the Activation parameters: - in: query name: force schema: type: boolean description: Force disable after worker node offline - in: path name: id schema: type: integer description: A unique integer value identifying this activation. required: true tags: - Activations security: - EDAJWTAuthentication: [] responses: '204': description: Activation has been disabled. '409': description: Activation blocked while Workers offline. x-ai-description: Disable an activation by ID. Stops the rulebook process if running. summary: Activations disable create x-summary-source: derived /activations/{id}/enable/: post: operationId: activations_enable_create description: Enable the Activation parameters: - in: path name: id schema: type: integer description: A unique integer value identifying this activation. required: true tags: - Activations security: - EDAJWTAuthentication: [] responses: '204': description: Activation has been enabled. '400': description: Activation not enabled. '409': description: Processing of enable is disallowed. x-ai-description: Enable an activation by ID. Starts the rulebook process if valid. summary: Activations enable create x-summary-source: derived /activations/{id}/restart/: post: operationId: activations_restart_create description: Restart the Activation parameters: - in: query name: force schema: type: boolean description: Force restart after worker node offline - in: path name: id schema: type: integer description: A unique integer value identifying this activation. required: true tags: - Activations security: - EDAJWTAuthentication: [] responses: '204': description: Activation restart was successful. '400': description: Activation not enabled. '409': description: Activation blocked while Workers offline. summary: Activations restart create x-summary-source: derived components: schemas: DecisionEnvironmentRef: type: object description: Serializer for DecisionEnvironment reference. properties: id: type: integer readOnly: true name: type: string description: type: string image_url: type: string pull_policy: allOf: - $ref: '#/components/schemas/PullPolicyEnum' description: 'Pull policy for the image before running * `always` - Always pull container before running. * `missing` - Only pull the image if not present before running. * `never` - Never pull container before running.' organization_id: type: integer readOnly: true required: - id - image_url - name - organization_id LogLevelEnum: enum: - debug - info - error type: string description: '* `debug` - debug * `info` - info * `error` - error' ScmTypeEnum: enum: - git type: string description: '* `git` - Git' RulebookRef: type: object description: Serializer for Rulebook reference. properties: id: type: integer readOnly: true name: type: string description: type: - string - 'null' organization_id: type: integer readOnly: true required: - id - name - organization_id ActivationInstance: type: object description: Serializer for the Activation Instance model. properties: id: type: integer readOnly: true name: type: string status: $ref: '#/components/schemas/StatusEnum' git_hash: type: string status_message: type: - string - 'null' activation_id: type: - integer - 'null' readOnly: true organization_id: type: integer readOnly: true started_at: type: string format: date-time readOnly: true ended_at: type: - string - 'null' format: date-time readOnly: true queue_name: type: - string - 'null' readOnly: true required: - activation_id - ended_at - id - organization_id - queue_name - started_at CredentialTypeRef: type: object properties: id: type: integer readOnly: true name: type: string namespace: type: - string - 'null' kind: type: string required: - id - name OrganizationRef: type: object properties: id: type: integer readOnly: true name: type: string description: The name of this resource. maxLength: 512 description: type: string description: The organization description. required: - id - name EdaCredential: type: object properties: name: type: string description: type: string inputs: type: object additionalProperties: true readOnly: true credential_type: allOf: - $ref: '#/components/schemas/CredentialTypeRef' references: type: - array - 'null' items: $ref: '#/components/schemas/EdaCredentialReference' created_by: type: object properties: id: type: integer username: type: string first_name: type: string last_name: type: string modified_by: type: object properties: id: type: integer username: type: string first_name: type: string last_name: type: string id: type: integer readOnly: true created_at: type: string format: date-time readOnly: true modified_at: type: string format: date-time readOnly: true managed: type: boolean readOnly: true organization: $ref: '#/components/schemas/OrganizationRef' required: - created_at - created_by - id - inputs - managed - modified_at - modified_by - name - organization PatchedActivationUpdate: type: object description: Serializer for updating the Activation. properties: name: type: string description: type: string is_enabled: type: boolean restart_on_project_update: type: boolean description: Auto-restart when rulebook changes after project sync decision_environment_id: type: integer rulebook_id: type: integer extra_var: type: - string - 'null' organization_id: type: integer user: type: - integer - 'null' restart_policy: $ref: '#/components/schemas/RestartPolicyEnum' awx_token_id: type: - integer - 'null' log_level: $ref: '#/components/schemas/LogLevelEnum' eda_credentials: type: array items: type: integer k8s_service_name: type: - string - 'null' source_mappings: type: string description: Mapping between sources and event streams skip_audit_events: type: boolean description: Skip audit events for activation enable_persistence: type: boolean description: Enable persistence for activation rule_engine_credential_id: type: - integer - 'null' k8s_pod_service_account_name: type: - string - 'null' k8s_pod_labels: {} k8s_pod_annotations: {} k8s_pod_node_selector: {} k8s_pod_tolerations: {} ActivationList: type: object description: Serializer for listing the Activation model objects. properties: id: type: integer readOnly: true name: type: string description: type: string is_enabled: type: boolean status: $ref: '#/components/schemas/StatusEnum' restart_on_project_update: type: boolean description: Auto-restart when rulebook changes after project sync extra_var: type: - string - 'null' decision_environment_id: type: - integer - 'null' readOnly: true project: allOf: - $ref: '#/components/schemas/ProjectRef' project_id: type: - integer - 'null' readOnly: true rulebook_id: type: - integer - 'null' readOnly: true organization_id: type: integer readOnly: true restart_policy: $ref: '#/components/schemas/RestartPolicyEnum' restart_count: type: integer maximum: 2147483647 minimum: -2147483648 rulebook_name: type: string description: Name of the referenced rulebook current_job_id: type: - string - 'null' rules_count: type: integer rules_fired_count: type: integer created_at: type: string format: date-time readOnly: true modified_at: type: string format: date-time readOnly: true edited_at: type: - string - 'null' format: date-time created_by: type: object properties: id: type: integer username: type: string first_name: type: string last_name: type: string modified_by: type: object properties: id: type: integer username: type: string first_name: type: string last_name: type: string edited_by: type: object properties: id: type: integer username: type: string first_name: type: string last_name: type: string status_message: type: - string - 'null' awx_token_id: type: - integer - 'null' readOnly: true log_level: $ref: '#/components/schemas/LogLevelEnum' eda_credentials: type: - array - 'null' items: $ref: '#/components/schemas/EdaCredential' k8s_service_name: type: - string - 'null' description: Service name of the activation event_streams: type: - array - 'null' items: $ref: '#/components/schemas/EventStreamOut' source_mappings: type: string description: Mapping between sources and event streams skip_audit_events: type: boolean description: Skip audit events for activation log_tracking_id: type: string readOnly: true enable_persistence: type: boolean description: Enable persistence for activation rule_engine_credential_id: type: - integer - 'null' description: The Rule Engine Credential to use, if empty use the default system rule engine credential. readOnly: true k8s_pod_service_account_name: type: - string - 'null' description: Kubernetes ServiceAccount for activation job pods k8s_pod_labels: {} k8s_pod_annotations: {} k8s_pod_node_selector: {} k8s_pod_tolerations: description: Kubernetes tolerations applied to activation job pods so they can be scheduled onto tainted nodes. required: - awx_token_id - created_at - created_by - decision_environment_id - edited_by - id - log_tracking_id - modified_at - modified_by - name - organization_id - project_id - rule_engine_credential_id - rulebook_id - rulebook_name - rules_count - rules_fired_count ActivationCopy: type: object properties: name: type: string required: - name EdaCredentialReference: type: object properties: type: type: string description: Type of the related resource id: type: integer description: ID of the related resource name: type: string description: Name of the related resource uri: type: string format: uri description: URI of the related resource required: - id - name - type - uri EdaCredentialRef: type: object description: Serializer for EdaCredential reference. properties: id: type: integer readOnly: true name: type: string description: type: string inputs: type: object additionalProperties: true readOnly: true managed: type: boolean credential_type_id: type: - integer - 'null' readOnly: true organization_id: type: integer readOnly: true required: - credential_type_id - id - inputs - name - organization_id StatusEnum: enum: - starting - running - pending - failed - stopping - stopped - deleting - completed - unresponsive - error - workers offline type: string description: '* `starting` - starting * `running` - running * `pending` - pending * `failed` - failed * `stopping` - stopping * `stopped` - stopped * `deleting` - deleting * `completed` - completed * `unresponsive` - unresponsive * `error` - error * `workers offline` - workers offline' PullPolicyEnum: enum: - always - missing - never type: string description: '* `always` - Always pull container before running. * `missing` - Only pull the image if not present before running. * `never` - Never pull container before running.' RestartPolicyEnum: enum: - always - on-failure - never type: string description: '* `always` - always * `on-failure` - on-failure * `never` - never' ActivationRead: type: object description: Serializer for reading the Activation with related objects info. properties: id: type: integer readOnly: true name: type: string description: type: string is_enabled: type: boolean decision_environment: allOf: - $ref: '#/components/schemas/DecisionEnvironmentRef' status: $ref: '#/components/schemas/StatusEnum' git_hash: type: string restart_on_project_update: type: boolean description: Auto-restart when rulebook changes after project sync project: allOf: - $ref: '#/components/schemas/ProjectRef' rulebook: allOf: - $ref: '#/components/schemas/RulebookRef' extra_var: type: - string - 'null' organization: $ref: '#/components/schemas/OrganizationRef' instances: type: array items: $ref: '#/components/schemas/ActivationInstance' restart_policy: $ref: '#/components/schemas/RestartPolicyEnum' restart_count: type: integer maximum: 2147483647 minimum: -2147483648 rulebook_name: type: string description: Name of the referenced rulebook current_job_id: type: - string - 'null' ruleset_stats: type: string description: The stat information about the activation rules_count: type: integer rules_fired_count: type: integer created_at: type: string format: date-time readOnly: true modified_at: type: string format: date-time readOnly: true edited_at: type: - string - 'null' format: date-time created_by: type: object properties: id: type: integer username: type: string first_name: type: string last_name: type: string modified_by: type: object properties: id: type: integer username: type: string first_name: type: string last_name: type: string edited_by: type: object properties: id: type: integer username: type: string first_name: type: string last_name: type: string restarted_at: type: - string - 'null' format: date-time status_message: type: - string - 'null' awx_token_id: type: - integer - 'null' readOnly: true eda_credentials: type: - array - 'null' items: $ref: '#/components/schemas/EdaCredential' log_level: $ref: '#/components/schemas/LogLevelEnum' k8s_service_name: type: - string - 'null' description: Service name of the activation k8s_pod_service_account_name: type: - string - 'null' description: Kubernetes ServiceAccount for activation job pods k8s_pod_labels: {} k8s_pod_annotations: {} k8s_pod_node_selector: {} event_streams: type: - array - 'null' items: $ref: '#/components/schemas/EventStreamOut' source_mappings: type: string description: Mapping between sources and event streams skip_audit_events: type: boolean description: Skip audit events for activation log_tracking_id: type: - string - 'null' description: Log tracking ID of the activation enable_persistence: type: boolean description: Enable persistence for activation rule_engine_credential_id: type: - integer - 'null' description: The Rule Engine Credential to use, if empty use the default system rule engine credential. readOnly: true rule_engine_credential: allOf: - $ref: '#/components/schemas/EdaCredential' k8s_pod_tolerations: description: Kubernetes tolerations applied to activation job pods so they can be scheduled onto tainted nodes. required: - awx_token_id - created_at - created_by - edited_by - id - instances - modified_at - modified_by - name - organization - rule_engine_credential_id - rulebook_name - rules_count - rules_fired_count - ruleset_stats ActivationCreate: type: object description: Serializer for creating the Activation. properties: name: type: string description: type: string is_enabled: type: boolean restart_on_project_update: type: boolean description: Auto-restart when rulebook changes after project sync decision_environment_id: type: integer rulebook_id: type: integer extra_var: type: - string - 'null' organization_id: type: integer restart_policy: $ref: '#/components/schemas/RestartPolicyEnum' awx_token_id: type: - integer - 'null' log_level: $ref: '#/components/schemas/LogLevelEnum' eda_credentials: type: array items: type: integer k8s_service_name: type: - string - 'null' source_mappings: type: string description: Mapping between sources and event streams skip_audit_events: type: boolean description: Skip audit events for activation enable_persistence: type: boolean description: Enable persistence for activation rule_engine_credential_id: type: - integer - 'null' k8s_pod_service_account_name: type: - string - 'null' k8s_pod_labels: {} k8s_pod_annotations: {} k8s_pod_node_selector: {} k8s_pod_tolerations: {} required: - decision_environment_id - name - organization_id - rulebook_id ProjectRef: type: object properties: id: type: integer readOnly: true git_hash: type: string url: type: string scm_type: $ref: '#/components/schemas/ScmTypeEnum' name: type: string description: type: string organization_id: type: integer readOnly: true update_revision_on_launch: type: boolean description: Enable automatic project sync on activation launch scm_update_cache_timeout: type: integer maximum: 2147483647 minimum: -2147483648 description: Cache timeout in seconds for project updates (0 = always update, max 86400) required: - git_hash - id - name - organization_id - url PaginatedActivationListList: type: object properties: count: type: integer example: 123 next: type: - string - 'null' format: uri example: /eda/api/v1/example/?page=51&page_size=100 previous: type: - string - 'null' format: uri example: /eda/api/v1/example/?page=49&page_size=100 page_size: type: - integer - 'null' example: 100 page: type: - integer - 'null' example: 50 results: type: array items: $ref: '#/components/schemas/ActivationList' EventStreamOut: type: object properties: name: type: string test_mode: type: boolean description: Enable test mode additional_data_headers: type: string description: The additional http headers which will be added to the event data. The headers are comma delimited organization: type: string readOnly: true eda_credential: $ref: '#/components/schemas/EdaCredentialRef' event_stream_type: type: string description: The type of the event stream based on credential type uuid: type: string format: uuid created_by: type: object properties: id: type: integer username: type: string first_name: type: string last_name: type: string modified_by: type: object properties: id: type: integer username: type: string first_name: type: string last_name: type: string id: type: integer readOnly: true owner: type: string readOnly: true url: type: string readOnly: true created_at: type: string format: date-time readOnly: true modified_at: type: string format: date-time readOnly: true test_content_type: type: string readOnly: true description: The content type of test data, when in test mode test_content: type: string readOnly: true description: The content recieved, when in test mode, stored as a yaml string test_error_message: type: string readOnly: true description: The error message, when in test mode test_headers: type: string readOnly: true description: The headers recieved, when in test mode, stored as a yaml string events_received: type: integer readOnly: true description: The total number of events received by event stream last_event_received_at: type: - string - 'null' format: date-time readOnly: true description: The date/time when the last event was received required: - created_at - created_by - eda_credential - events_received - id - last_event_received_at - modified_at - modified_by - name - organization - owner - test_content - test_content_type - test_error_message - test_headers - url PaginatedActivationInstanceList: type: object properties: count: type: integer example: 123 next: type: - string - 'null' format: uri example: /eda/api/v1/example/?page=51&page_size=100 previous: type: - string - 'null' format: uri example: /eda/api/v1/example/?page=49&page_size=100 page_size: type: - integer - 'null' example: 100 page: type: - integer - 'null' example: 50 results: type: array items: $ref: '#/components/schemas/ActivationInstance' securitySchemes: EDAJWTAuthentication: type: apiKey name: X-DAB-JW-TOKEN in: header cookieAuth: type: apiKey in: cookie name: sessionid