Set Line of Business on Ticket at Creation

We have a use case to limit ticket visibility for specific co-managed user groups based upon line of business (Organizational Structure). More specifically for co-managed users to see tickets that align with their department which we plan to tie to the ticket queue. It would be possible to set this with a workflow rule, which makes sense based on changing a queue (edit) of a ticket, but not as much on a ticket creation.

In review of additional fields that can be selected it looks like “BusinessDivisionSubdivisionID” is the correct field, but I’m unsure how to find or assemble that unique ID. Is this approach possible?

You are correct that the Line of Business field in the Autotask UI is called BusinessDivisionSubdivisionID in the API.

This diagram shows how the BusinessDivisionSubdivisionID points to the BusinessDivision and Business Subdivision records that actually contain the friendly names of the objects.

It is possible to build a script in Email2AT that uses the BusinessDivsion Name and BusinessSubdivision Name to find the ID of the BusinessDivisionSubdivisionID you need to assign LOB on a ticket.

But I think this is an easier method:

  1. Create a test ticket and assign it to the Line of Business you need and note its Ticket Number.
  2. Create a test Email2AT script that finds this ticket number and then emails you the value of BusinessDivisionSubdivisionID. If you have the Schedule Tasks feature in Email2AT you can create a unscheduled task and run it manually. If you do not have Scheduled Tasks you will need to send an email that triggers your test script.
  3. Run or Trigger the script and you will receive an email with the value of BusinessDivisionSubdivisionID.
  4. Use this value in your script to assign a ticket, new or modified, to the proper LOB.

Let me know of you need more details on how to create the script or have other questions.


Thank you for reporting this issue, @maglaubig-offsite . The MSPintegrations console should display the correct name of the line of business, but it does not. We will fix this in the next release and notify you when it’s resolved.

Looking forward to it!

In searching around on the topic and a support request with Autotask support, I believe Email2AT is using the SOAP 1.6 API. That was part of my confusion in terms, I thought everything was REST API. I opened up a ticket with support to ask how do request this same info as REST and they pointed me to an API swagger reference that I figured I should pass along:

These tables in BusinessDivisionSubdivision map to tables OrganizationalLevel1, OrganizationalLevel2 and OrganizationalLevelAssociation.

I appreciate this very much!

As I replied to Travis, I was looking at REST API references not SOAP. I did however come across another way to get at the info that I wanted to pass along because it can help others:

You can run the queries right through the website. I suspect that the URL may change based depending on where your Autotask is deployed.