Process Integration/API PUT or POST to add Configuration Item?

The API documentation leads one to believe that it's possible to add configuration items by id to a ticket at creation or by updating, but I can't seem to make it work.

We're working on an inventory clean up and need to generate dozens of tickets over the course of several weeks to track the work. I need to be able to attach the related computers to the tickets. 

I definitely don't want to have to generate each ticket by hand, searching for and selecting each individual computer to relate it to the ticket, when I have CSV files I've generated with all the data required to plug into automated tickets.

I don't care if it's JSON or XML, I'd just like to not do this manually.

Parents Reply Children
  • Sorry, the image insertion function here is terrible. I have a "SW ID" custom input field for the form. Here's the text of what's set:

    ~~~~~~~~~~~~

    Integration*
    HTTP Method
    URL
    https://api.samanage.com/incidents/{{context_id}}
    Retries* 1
    PARAMETERS APPENDED TO URL
    (none)
    ADDITIONAL HEADERS
    Name*
    Content-Type
    Value*
    application/xml
    BODY
    <incident>
    <assets>
    <asset>
    <id>{{SW ID}}</id>
    </asset>
    </assets>
    </incident>
    ~~~~~~~~~

    Hope this helps!

  • I like to use postman to test the APIs. You get a lot better detail on the errors n such. I noticed that you aren't using the x-smanage auth bearer token. Maybe you omitted that for security reasons. But here is what Im passing, obviously mine is blurred out.