This module is part of the servicenow.itsm collection (version 2.7.0).
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install servicenow.itsm
.
To use it in a playbook, specify: servicenow.itsm.problem_task
.
New in servicenow.itsm 1.3.0
- Create, delete or update ServiceNow problem tasks.
- For more information, refer to the ServiceNow problem management documentation at https://docs.servicenow.com/bundle/tokyo-it-service-management/page/product/problem-management/concept/c_ProblemManagement.html.
Parameter |
Comments |
|
---|---|---|
assigned_to string |
Specific problem analyst to whom the task is assigned to. |
|
assignment_group string |
Specific group to whom the problem task is assigned to. |
|
close_code string |
Provide information on how the change task was resolved. The change task must have this parameter set prior to transitioning to the Choices:
|
|
close_notes string |
Resolution notes added by the user who closed the change task. The change task must have this parameter set prior to transitioning to the |
|
configuration_item string |
Configuration item (CI) that the problem applies to. The CI class of the selected configuration item identifies the type of problem. |
|
description string |
Detailed description of the problem task. |
|
due_date string |
Date within which the problem task should be completed. |
|
instance dictionary |
ServiceNow instance information. |
|
access_token string added in servicenow.itsm 2.3.0 |
Access token obtained via OAuth authentication. If not set, the value of the |
|
api_path string added in servicenow.itsm 2.4.0 |
Change the API endpoint of SNOW instance from default 'api/now'. Default: |
|
client_id string |
ID of the client application used for OAuth authentication. If not set, the value of the If provided, it requires client_secret. |
|
client_secret string |
Secret associated with client_id. Used for OAuth authentication. If not set, the value of the If provided, it requires client_id. |
|
custom_headers dictionary added in servicenow.itsm 2.4.0 |
A dictionary containing any extra headers which will be passed with the request. |
|
grant_type string added in servicenow.itsm 1.1.0 |
Grant type used for OAuth authentication. If not set, the value of the Since version 2.3.0, it no longer has a default value in the argument specifications. If not set by any means, the default value (that is, password) will be set internally to preserve backwards compatibility. Choices:
|
|
host string / required |
The ServiceNow host name. If not set, the value of the |
|
password string |
Password used for authentication. If not set, the value of the Required when using basic authentication or when grant_type=password. |
|
refresh_token string added in servicenow.itsm 1.1.0 |
Refresh token used for OAuth authentication. If not set, the value of the Required when grant_type=refresh_token. |
|
timeout float |
Timeout in seconds for the connection with the ServiceNow instance. If not set, the value of the |
|
username string |
Username used for authentication. If not set, the value of the Required when using basic authentication or when grant_type=password. |
|
validate_certs boolean added in servicenow.itsm 2.3.0 |
If host's certificate is validated or not. Choices:
|
|
number string |
Number of the record to operate on. Note that contrary to sys_id, number may not uniquely identify a record. |
|
other dictionary |
Optional remaining parameters. For more information on optional parameters, refer to the ServiceNow create problem task documentation at https://docs.servicenow.com/bundle/tokyo-it-service-management/page/product/problem-management/task/create-problem-task.html. |
|
priority string |
How quickly the service desk should address the problem task. Default choices are |
|
problem_task_mapping dictionary added in servicenow.itsm 1.3.0 |
User mapping for Problem task object, where user can override Choice Lists values for objects. |
|
priority dictionary |
How quickly the service desk should address the problem task. |
|
state dictionary |
State of problem tasks. If state value is |
|
short_description string |
Brief description of the problem task. |
|
source_problem string |
Number of the problem for which the problem task is created. |
|
state string |
State of problem tasks. If state value is Default choices are |
|
sys_id string |
Unique identifier of the record to operate on. |
|
type string |
Read-only state. Determines whether the problem task is created specifically to investigate the cause of the problem or is a general task. Choices:
|
servicenow.itsm.problem_task_info
List ServiceNow problem tasks.
-
Manage ServiceNow problems.
-
List ServiceNow problems.
- name: Create problem task
servicenow.itsm.problem_task:
instance:
host: https://instance_id.service-now.com
username: user
password: pass
state: new
type: general
source_problem: PRB0000001
short_description: User is not receiving email
description: User has been unable to receive email for the past 15 minutes
priority: low
- name: Change state of the problem task
servicenow.itsm.problem_task:
instance:
host: https://instance_id.service-now.com
username: user
password: pass
number: PTASK0010005
state: assess
assigned_to: fred.luddy
- name: Close problem task
servicenow.itsm.problem_task:
instance:
host: https://instance_id.service-now.com
username: user
password: pass
state: closed
number: PTASK0010005
close_code: canceled
close_notes: Closed
- name: Delete problem task
servicenow.itsm.problem_task:
instance:
host: https://instance_id.service-now.com
username: user
password: pass
state: absent
number: PTASK0010005
The following are the fields unique to this module:
- Manca Bizjak (@mancabizjak)
- Miha Dolinar (@mdolin)
- Tadej Borovsak (@tadeboro)