[rt-users] Create transaction content field is empty (only) when a ticket is created by the API.

Ben Kolera bkolera at iseek.com.au
Tue Nov 5 00:57:26 EST 2013


Hi Everyone,

We¹ve recently updated to RT 4.2.0 in our testing enviroment and I¹ve
noticed a weird discrepency between it and 4.0.17, specifically to do with
the API. If anyone has any pointers I¹d be most grateful! :)

So I can create a ticket through the API as I normally would just fine:

----

rt> create ­t ticket

# Required: id, Queue

id: ticket/new
Queue: facilities
Requestor: iseekportal
Subject: Test
Status: new
Text: This is a test

# Ticket 1019332 created.

----

But then when I try to view the history the text that I created the ticket
with is no longer part of the Create transaction content. It definitely is
returning as part of the content in 4.0.17.

----

rt> show -l ticket/1019332/history
# 3/3 (id/11733911/total)

id: 11733911
Ticket: 1019332
TimeTaken: 0
Type: Create
Field:
OldValue:
NewValue:
Data:
Description: Ticket created by iseekportal
Content:
Creator: iseekportal
Created: 2013-11-05 05:22:05

Attachments:
             5558318: untitled (0b)
             5558319: untitled (0b)
             5558320: untitled (15b)

----

It is, of course, one of the attachments.

----

rt> show -l ticket/1019332/attachments/5558320
id: 5558320
Subject:
Creator: 3369756
Created: 2013-11-05 05:22:05
Transaction: 11733911
Parent: 5558318
MessageId:
Filename:
ContentType: text/plain
ContentEncoding: none

Headers: Content-Disposition: inline
         Content-Transfer-Encoding: binary
         Content-Type: text/plain
         Content-Length: 15

Content: This is a test!

----

But if I create a ticket via the web ui and view the history via the API
the text body of the create transaction is exactly how I¹d expect it to be.

----

rt> show -l ticket/1019334/history
# 3/3 (id/11733925/total)

id: 11733925
Ticket: 1019334
TimeTaken: 0
Type: Create
Field:
OldValue:
NewValue:
Data:
Description: Ticket created by iseekportal
Content: Testing from the web UI!
Creator: iseekportal
Created: 2013-11-05 05:30:16

Attachments:
             5558332: untitled (24b)


----

So my long winded question is, ³Is this behaviour intended and should I
change my automations to trawl through the transaction attachments to get
at the Create body?². It may be noteworthy that even comments and
correspondences from the API seem to be populating the transaction Content
field properly when read out, so it is only the Create call, and only when
it is done through the API; which leads me to believe (and hope!) that
this is just an unintended bug.

--
Ben Kolera
Team Leader, Development
http://www.iseek.com.au <http://www.iseek.com.au/>
46 Logan Road Woolloongabba QLD 4102




More information about the rt-users mailing list