SOAP Documentation: Documents

Overview

This resource provides methods to manage Supplier and Supplier Item documents.


Operations List

The Operations List for this resource: Documents Operations List.


Resource WSDL

The WSDL for this resource can be found here: Documents WSDL.


Endpoint URLs

All requests should be sent to one of the following:
      Production Environment: https://api.tracegains.net/v7/soap/Documents.asmx.
      Test Environment: https://api-test.tracegains.net/v7/soap/Documents.asmx.


Create

Enterprise | SM QM

 Creates a new Supplier or Supplier Item Document.

Notes:

All documents require a document Type already configured in your TraceGains instance and will fail upload if one is not provided. However, this method will create a new Status and Workflow if the values you provide do not currently exist in your instance configuration.

  • The property document.SupplierID is required when uploading a Supplier document.
  • The properties document.SupplierID and document.ItemID are required when uploading a Supplier Item document.
  • The property document.ExpirationDate may be automatically calculated based on your TraceGains instance Document Type rules and configuration.

Request:

Parameter Type Description
appKey Guid A registered and active Application Key.
sessionId Guid An active Session ID.
document Document The document definition to create.

Response:

RequestResult The default response. This response can take on a different XML element name depending on the development IDE/toolset being used.

Delete

Enterprise | SM SC SPM FM QM

 Deletes a Document by its ID.


Request:

Parameter Type Description
appKey Guid A registered and active Application Key.
sessionId Guid An active Session ID.
documentId Integer The ID of the Document to delete.

Response:

RequestResult The default response. This response can take on a different XML element name depending on the development IDE/toolset being used.

Get

Enterprise | SM SC SPM FM QM

 Gets a Document by its ID.


Request:

Parameter Type Description
appKey Guid A registered and active Application Key.
sessionId Guid An active Session ID.
documentId Integer The ID of the Document to return.
includeByteArray Boolean Determines weather or not to return the document data as a Base64Binary byte array.

Response:

Element Type Description
ResponseCode ResponseCode A valid HTTP status code.
Message String A log friendly message.
Document DocumentResult The returned Document record.

List

Enterprise | SM QM

 Returns a paged list of Documents for a Supplier or Supplier Item.

Notes:

The document bytes are NOT currently returned in this method because of the additional processing overhead. You must call the Get method of this endpoint to retrieve the document bytes for a document returned in the list.


Request:

Parameter Type Description
appKey Guid A registered and active Application Key.
sessionId Guid An active Session ID.
supplierId String The ID of a valid Supplier.
itemId String (Optional) The ID of a valid Item.
includeArchived Boolean Indicates whether to return archived documents in the result.
pageCriteria PagingCriteria Row index paging criteria.

Response:

Element Type Description
ResponseCode ResponseCode A valid HTTP status code.
Message String A log friendly message.
Document
repeating
DocumentResult The list of returned Document records.

ListStatuses

Enterprise | SM SC SPM FM QM

 Lists all active document Statuses.


Request:

Parameter Type Description
appKey Guid A registered and active Application Key.
sessionId Guid An active Session ID.

Response:

ListResult This response could take on a different XML element name by method.

ListTypes

Enterprise | SM SC SPM FM QM

 Lists all active document Types.


Request:

Parameter Type Description
appKey Guid A registered and active Application Key.
sessionId Guid An active Session ID.

Response:

ListResult This response could take on a different XML element name by method.

ListWorkflows

Enterprise | SM SC SPM FM QM

 Lists all active document Workflows.


Request:

Parameter Type Description
appKey Guid A registered and active Application Key.
sessionId Guid An active Session ID.

Response:

ListResult This response could take on a different XML element name by method.

Query

Enterprise | SM QM

 Returns a paged list of Documents using more advanced request parameters.

Notes:

This method queries raw record data in your TraceGains instance using contains or partial match filtering for all attribute data provided in the filterValues parameter. This behavior is consistent with grid view filtering in the TraceGains UI and reduces the amount of calls to the method required to find similarly sequenced data.


Request:

Parameter Type Description
appKey Guid A registered and active Application Key.
sessionId Guid An active Session ID.
fromModifiedDate DateTime ISO 8601 formatted date/time string in Coordinated Universal Time (UTC). Returns Documents that have been modified after this date and time.
toModifiedDate DateTime ISO 8601 formatted date/time string in Coordinated Universal Time (UTC). Returns Documents that have been modified before this date and time.
pageCriteria PagingCriteria Row index paging criteria.
attributeType AttributeRequestType Determines what type of Attributes to return.
filterValues
repeating
AttributeValue A list of attribute-value pairs to filter returned Documents. Attributes must be of type Document as defined in AttributeUseType. All others will be ignored.

Response:

Element Type Description
ResponseCode ResponseCode A valid HTTP status code.
Message String A log friendly message.
Document
repeating
DocumentResult The list of returned Document records.

Update

Enterprise | SM SC SPM FM QM

 Updates an existing Supplier or Supplier Item Document.

Notes:

Only properties, document META, may be updated with this method. To replace an existing document with a new document, delete the original document and create a new replacement document using the Create method.

  • Several document properties are ignored by this method including, but not limited to, FileName and ByteArray. Ignored properties may change based on feature updates to the Manage Document view in your TraceGains UI.
  • A document can be moved to another Supplier or Supplier Item by updating the properties document.SupplierID and document.ItemID.

Request:

Parameter Type Description
appKey Guid A registered and active Application Key.
sessionId Guid An active Session ID.
document Document The document definition to create.

Response:

RequestResult The default response. This response can take on a different XML element name depending on the development IDE/toolset being used.

Version

 Reports the version information of this resource.


Request:

No Parameters


Response:

Element Type Description
ResponseCode ResponseCode A valid HTTP Status Code
Message String A log friendly message that can be used in troubleshooting a failed response.
Version String The major, minor, and build number of this resource.