Ansible Tower Endpoint Configuration in ServiceNow Catalog.
Endpoint:- https://loadbalancer IP/api/v2/job_templates/45/launch
Note:- Our load balancer is configured with three Ansible Towers.
Response from Ansible to ServiceNow after Data Post:-
Response body {“job”:11163,“ignored_fields”:{},“id”:11163,“type”:“job”,“url”:“/api/v2/jobs/11163/”,“related”:{“created_by”:“/api/v2/users/1/”,“modified_by”:“/api/v2/users/1/”,“labels”:“/api/v2/jobs/11163/labels/”,“inventory”:“/api/v2/inventories/1/”,“project”:“/api/v2/projects/4/”,“organization”:“/api/v2/organizations/1/”,“extra_credentials”:“/api/v2/jobs/11163/extra_credentials/”,“credentials”:“/api/v2/jobs/11163/credentials/”,“unified_job_template”:“/api/v2/job_templates/45/”,“stdout”:“/api/v2/jobs/11163/stdout/”,“job_events”:“/api/v2/jobs/11163/job_events/”,“job_host_summaries”:“/api/v2/jobs/11163/job_host_summaries/”,“activity_stream”:“/api/v2/jobs/11163/activity_stream/”,“notifications”:“/api/v2/jobs/11163/notifications/”,“create_schedule”:“/api/v2/jobs/11163/create_schedule/”,“job_template”:“/api/v2/job_templates/45/”,“cancel”:“/api/v2/jobs/11163/cancel/”,“relaunch”:“/api/v2/jobs/11163/relaunch/”},“summary_fields”:{“organization”:{“id”:1,“name”:“AACB CMP”,“description”:“”},“inventory”:{“id”:1,“name”:“AACB Inventory”,“description”:“”,“has_active_failures”:false,“total_hosts”:0,“hosts_with_active_failures”:0,“total_groups”:0,“has_inventory_sources”:false,“total_inventory_sources”:0,“inventory_sources_with_failures”:0,“organization_id”:1,“kind”:“”},“project”:{“id”:4,“name”:“AACB CMP Project”,“description”:" CMP Project",“status”:“ok”,“scm_type”:“”},“job_template”:{“id”:45,“name”:“Linux DMZ VM build-RHEL8”,“description”:“Linux DMZ VM build-RHEL8”},“unified_job_template”:{“id”:45,“name”:“Linux DMZ VM build-RHEL8”,“description”:“Linux DMZ VM build-RHEL8”,“unified_job_type”:“job”},“created_by”:{“id”:1,“username”:“admin”,“first_name”:“”,“last_name”:“”},“modified_by”:{“id”:1,“username”:“admin”,“first_name”:“”,“last_name”:“”},“user_capabilities”:{“delete”:true,“start”:true},“labels”:{“count”:0,“results”:},“extra_credentials”:,“credentials”:[{“id”:1,“name”:“Prod credentials”,“description”:“Prod credentials”,“kind”:“ssh”,“cloud”:false}]},“created”:“2024-10-07T12:43:44.803687Z”,“modified”:“2024-10-07T12:43:44.851977Z”,“name”:“Linux DMZ VM build-RHEL8”,“description”:“Linux DMZ VM build-RHEL8”,“job_type”:“run”,“inventory”:1,“project”:4,“playbook”:“test_play/IaaS-Playbooks/prod/linux/NewVM/RHEL8_DMZ/dmz_build_rhel8.yml”,“scm_branch”:“”,“forks”:0,“limit”:“”,“verbosity”:0,“extra_vars”:“{"name": "gbvleuaacuaap01", "template": "RHEL8_GoldenTemplate", "size": "30", "size_1": "20", "ram": "16384", "cpu": "4", "ritm": "SCTASK0499743", "ip_adr": null, "server_role": null, "app": "Ansible Automation Platform ", "dev": "u", "ser": null, "siteid": null, "vmtype": null, "iteration": "1", "tier": "", "protection": "", "epg": "LON-EDMZNP-ANSIBL01", "applicationref": "aap", "network": "EDMZ", "justification": "As per Request Number xyz.", "user": "Marek ", "serviceclass": "Bronze"}”,“job_tags”:“”,“force_handlers”:false,“skip_tags”:“”,“start_at_task”:“”,“timeout”:0,“use_fact_cache”:true,“organization”:1,“unified_job_template”:45,“launch_type”:“manual”,“status”:“pending”,“failed”:false,“started”:null,“finished”:null,“canceled_on”:null,“elapsed”:0.0,“job_args”:“”,“job_cwd”:“”,“job_env”:{},“job_explanation”:“”,“execution_node”:“”,“controller_node”:“”,“result_traceback”:“”,“event_processing_finished”:false,“job_template”:45,“passwords_needed_to_start”:,“allow_simultaneous”:true,“artifacts”:{},“scm_revision”:“”,“instance_group”:null,“diff_mode”:false,“job_slice_number”:0,“job_slice_count”:1,“webhook_service”:“”,“webhook_credential”:null,“webhook_guid”:“”}