Get Text Attachment v2
/jderest/v2/file/gettext
Request
- application/json
-
jde-AIS-Auth(optional): string
Token
-
jde-AIS-Auth-Device(optional): string
Device Name
-
jde-AIS-MonitorOnStart(optional): boolean
Monitor on Start
-
jde-AIS-MonitorRequest(optional): string
Monitor RequestAllowed Values:
[ "monitorRequest", "monitorRequestIO" ]
object
-
deviceName(optional):
string
An identifier for the device making the service call. If not provided, the requesting IP address is used.
-
environment(optional):
string
Specify the environment to use for login. If not specified, the default environment configured for the AIS Server will be used.
-
formName:
string
The name of the form the media object is associated with (for example W01012A).
-
htmlText(optional):
boolean
When retriving HTML based text media objects indicate if response should include HTML tags (true) or convert to plain text (false). The default is false.
-
jasserver(optional):
string
The HTML (JAS) Server to use for login. If not specified, the default HTML Server configured for the AIS Server will be used.
-
moKey:
array moKey
An array of media object key values. You must pass the values in the same order that they appear in the data structure. The key values will be converted into the bar delimited key of the media object record stored in the F00165 table.
-
moStructure:
string
The media object data structure name, for example GT0801 or ABGT, which is a key to the F00165 table where media objects are stored.
-
multipleMode(optional):
boolean
A value of true indicates that the service should return all text media objects in an array. If a sequence number is provided, it will return just the requested text item in the array.
-
password(optional):
string
The JD Edwards EnterpriseOne password, which is required if other authentication methods are not being used.
-
psToken(optional):
string
Used for logging in with psToken. Primarily used by the HTML Server to establish a session with the AIS Server.
-
role(optional):
string
The role to use for login. If not specified, the default role configured for the AIS Server will be used.
-
sequence(optional):
integer(int32)
The sequence number of an individual text item being requested.
-
token(optional):
string
The AIS token, which is required if other authentication methods are not being used.
-
username(optional):
string
JD Edwards EnterpriseOne username, which is required if other authentication methods are not being used.
-
version:
string
The version of the application the media object is associated with (for example ZJDE0001).
array
Response
- application/json
200 Response
object
-
mediaObjects(optional):
array mediaObjects
The list of media object items.
array
-
Array of:
object MediaObjectListItem
MediaObjectListItem is an individual media object within the response returned from the list operation.
object
-
data(optional):
string
If this is an image and data was requested, this will contain a Base64 encoded string of the image, scaled down to thumbnail size based on the request.
-
deviceName(optional):
string
An identifier for the device making the service call. If not provided, the requesting IP address is used.
-
downloadUrl(optional):
string
For file type media objects this is the download URL needed ot download the item. Pass this value into a download request.
-
environment(optional):
string
Specify the environment to use for login. If not specified, the default environment configured for the AIS Server will be used.
-
file(optional):
string
The location of the file for this media object.
-
formName:
string
The name of the form the media object is associated with (for example W01012A).
-
isDefaultImage(optional):
boolean
Indicates that this image was set as the default image for this media object structure and key.
-
isImage(optional):
boolean
Indicates the file is an image.
-
isOLE(optional):
boolean
Indicates the item is an OLE item.
-
isShortCut(optional):
boolean
Indicates the item is a shortcut.
-
isText(optional):
boolean
Indicates the item is a text type media object.
-
isUpdated(optional):
boolean
Indicates the item has been updated.
-
isURL(optional):
boolean
Indicates the item is a URL type media object.
-
itemName(optional):
string
The name of the media object item.
-
jasserver(optional):
string
The HTML (JAS) Server to use for login. If not specified, the default HTML Server configured for the AIS Server will be used.
-
link(optional):
string
The if it's a URL type it will have the URL, for file types it will have the file location, for text types this field is not returned.
-
moKey:
array moKey
An array of media object key values. You must pass the values in the same order that they appear in the data structure. The key values will be converted into the bar delimited key of the media object record stored in the F00165 table.
-
moStructure:
string
The media object data structure name, for example GT0801 or ABGT, which is a key to the F00165 table where media objects are stored.
-
moType(optional):
integer(int32)
The media object type, 0-Text, 1-File, 5-URL.
-
password(optional):
string
The JD Edwards EnterpriseOne password, which is required if other authentication methods are not being used.
-
psToken(optional):
string
Used for logging in with psToken. Primarily used by the HTML Server to establish a session with the AIS Server.
-
queue(optional):
string
If the file was from the media object queue, the queue name will be returned.
-
role(optional):
string
The role to use for login. If not specified, the default role configured for the AIS Server will be used.
-
sequence(optional):
integer(int32)
The sequence number of the media object item.
-
token(optional):
string
The AIS token, which is required if other authentication methods are not being used.
-
updateDate(optional):
string
The date the media object was last updated.
-
updateHourOfDay(optional):
integer(int32)
The hour of the day the item was last updated.
-
updateMinuteOfHour(optional):
integer(int32)
The minute of the hour of the day the item was last updated.
-
updateSecondOfMinute(optional):
integer(int32)
The second of the minute of the hour day the item was last updated.
-
updateUserID(optional):
string
The user that last updated the item.
-
username(optional):
string
JD Edwards EnterpriseOne username, which is required if other authentication methods are not being used.
-
version:
string
The version of the application the media object is associated with (for example ZJDE0001).
array
400 Response
403 Response
415 Response
444 Response
object
-
errorText(optional):
string
-
exception(optional):
string
The class of the exception if an exception was thrown.
-
exceptionId(optional):
string
ExceptionId, only if an exception record was written to the F980060
-
message(optional):
string
Details about the error.
-
status(optional):
string
Allowed Values:
[ "ERROR", "WARNING" ]
Status determined by exception handling -
timeStamp(optional):
string
The timestamp indicating the time the error message was returned.
-
type(optional):
string
Optional type of error
-
userDefinedErrorText(optional):
string
Optional error text added to an orchestration step.
500 Response
object
-
errorText(optional):
string
-
exception(optional):
string
The class of the exception if an exception was thrown.
-
exceptionId(optional):
string
ExceptionId, only if an exception record was written to the F980060
-
message(optional):
string
Details about the error.
-
status(optional):
string
Allowed Values:
[ "ERROR", "WARNING" ]
Status determined by exception handling -
timeStamp(optional):
string
The timestamp indicating the time the error message was returned.
-
type(optional):
string
Optional type of error
-
userDefinedErrorText(optional):
string
Optional error text added to an orchestration step.
Examples
Example Request - First Text
The following shows an example of a media object request to get the first text media object based on the key. The token passed in this example was received from a separate token request.
curl -i -X POST -H "Content-Type:application/json" http://ais_server_url/v2/file/gettext -d { "token": "0440oeYB5hvl/zEsJvbJDUGRpPSK6kXSyoeiolMRcC6hrM=MDE5MDA4NDY4NzIwOTczNjY3MTg1OTA3OU15RGV2aWNlMTQ4MDcwMjYzNzcxMg==", "moStructure": "ABGT", "moKey": [ "7500" ], "formName": "P01012_W01012B", "version": "ZJDE0001" }
Example Response - First Text
The following example shows the contents of the response body.
{ "ssoEnabled" : false, "text" : "Text media object contents.", "isRTF" : false }
Example Request - All Text
The following shows an example of a media object request to get all text media objects based on the key.
curl -i -X POST -H "Content-Type:application/json" http://ais_server_url/v2/file/gettext -d { "token": "0440oeYB5hvl/zEsJvbJDUGRpPSK6kXSyoeiolMRcC6hrM=MDE5MDA4NDY4NzIwOTczNjY3MTg1OTA3OU15RGV2aWNlMTQ4MDcwMjYzNzcxMg==", "moStructure": "ABGT", "moKey": [ "7500" ], "multipleMode": true, "formName": "P01012_W01012B", "version": "ZJDE0001" }
Example Response - All Text
The following example shows the contents of the response body.
{"textAttachments": [ { "text": "Text 6 ? This is the First Text Object", "isRTF": false, "sequence": 6 "itemName": "Text6" }, { "text": "Text 8", "isRTF": false, "sequence": 8 "itemName": "Test Text Item" }, { "text": "Text 9", "isRTF": false, "sequence": 9 "itemName": "Text9" } ]}
Example Request - Single By Sequence
The following shows an example of a media object request to get a single text media object based on the key and sequence.
curl -i -X POST -H "Content-Type:application/json" http://ais_server_url/v2/file/gettext -d { "token": "0440oeYB5hvl/zEsJvbJDUGRpPSK6kXSyoeiolMRcC6hrM=MDE5MDA4NDY4NzIwOTczNjY3MTg1OTA3OU15RGV2aWNlMTQ4MDcwMjYzNzcxMg==", "moStructure": "ABGT", "moKey": [ "7500" ], "multipleMode": true, "sequence": 9, "formName": "P01012_W01012B", "version": "ZJDE0001" }
Example Response - Single By Sequence
The following example shows the contents of the response body.
{"textAttachments": [ { "text": "Text 9", "isRTF": false, "sequence": 9 "itemName": "Text9" } ]}