This site is in read only mode. Please continue to browse, but replying, likes, and other actions are disabled for now.

⚠️ We've moved!

Hi there!

To reduce project dependency on 3rd party paid services the StackStorm TSC has decided to move the Q/A from this forum to Github Discussions. This will make user experience better integrated with the native Github flow, as well as the questions closer to the community where they can provide answers.

Use 🔗 Github Discussions to ask your questions.

Error while working with Pagerduty incident acknowledge and other operations

Hi Team,

While i am using pagerduty plugin in st2 to acknowledge, resolve the incident i am getting an error like below.

As per what is asked in the plugin, i have provided api key, integration key and a valid Email with which i have user in pagerduty. Still i am not able to administer the triggers in pager duty and getting an above error. Can someone please help me out with this please?

st2.actions.python.PdAction: DEBUG    Initializing pypd client
st2.actions.python.PdAction: DEBUG    Checking if entity is defined: Incident
st2.actions.python.PdAction: DEBUG    Checking if method is defined: acknowledge
st2.actions.python.PdAction: DEBUG    Running an entity_id specific method
st2.actions.python.PdAction: DEBUG    Extracting entity_id from kwargs: PECMUVT
st2.actions.python.PdAction: DEBUG    running check_required(); inputs: {'entity_id': 'PECMUVT'}
st2.actions.python.PdAction: DEBUG    running a fetch() on Incident:PECMUVT
st2.actions.python.PdAction: DEBUG    Running pypd acknowledge on Incident:PECMUVT
Traceback (most recent call last):
  File "/opt/stackstorm/st2/lib/python3.6/site-packages/python_runner/python_action_wrapper.py", line 334, in <module>
    obj.run()
  File "/opt/stackstorm/st2/lib/python3.6/site-packages/python_runner/python_action_wrapper.py", line 193, in run
    output = action.run(**self._parameters)
  File "/opt/stackstorm/packs/pagerduty/actions/action.py", line 112, in run
    entity=entity, method=method, entity_id=entity_id, **kwargs))
  File "/opt/stackstorm/packs/pagerduty/actions/lib/base.py", line 173, in entity_id_method
    entity_id_method = getattr(source, method)(**kwargs)
  File "/opt/stackstorm/virtualenvs/pagerduty/lib/python3.6/site-packages/pypd/models/incident.py", line 64, in acknowledge
    data=data,)
  File "/opt/stackstorm/virtualenvs/pagerduty/lib/python3.6/site-packages/pypd/mixins.py", line 123, in request
    **kwargs
  File "/opt/stackstorm/virtualenvs/pagerduty/lib/python3.6/site-packages/pypd/mixins.py", line 72, in _do_request
    return self._handle_response(requests_method(*args, **kwargs))
  File "/opt/stackstorm/virtualenvs/pagerduty/lib/python3.6/site-packages/pypd/mixins.py", line 48, in _handle_response
    raise BadRequest(response.status_code, response.text)
pypd.errors.BadRequest: BadRequest (2010): Access Denied```

This happens to be related to user api key its working now.