getCategory Method

This article contains the following topics:
casm171
This article contains the following topics:
The following parameters apply to the getCategory method:
Parameter
Type
Description
SID
Integer
Identifies the session retrieved from logging in.
categoryId
Integer
Identifies the category ID in which to create the document.
getCategoryPaths
Boolean
Indicates the path for which to get category information. It returns category information and the full text category path for each category.
Description
Retrieves information for a category, including a listing of all of its child categories.
Returns
A <UDSObjectList> node with an <UDSObject> node describing the category requested.
getPermissionGroups
The following parameters apply to the getPermissionGroups method:
Parameter
Type
Description
SID
Integer
Identifies the session retrieved from logging in.
groupID
Integer
Returns only the group with this ID. Pass zero (0) when you do not want to use this parameter.
Note:
This groupID relates to a knowledge category, and differs from the groupID for contacts.
Description
Retrieves the list of Permission Groups.
Returns
A <UDSObject> node with zero or more <UDSObject> nodes describing Permission Group with the following <Attributes> child nodes:
XML Element Value
Type
Description
id
Integer
Identifies the unique ID of the group.
GRP_LIST_KEY
String
Shows a list of the IDs of CA SDM groups, separated by commas.
GRP_LIST
String
Displays a field containing the entire group list.
 
getComments
The following parameters apply to the getComments method:
Parameter
Type
Description
SID
Integer
Identifies the session retrieved from logging in.
docIds
String
Identifies the document IDs for all the comments you want to retrieve.
Note:
Use commas to separate, for example, "400001,400002".
Description
Gets all the comments from documents.
Returns
A <UDSObjectList> node with zero or more <UDSObject> nodes describing O_COMMENTS with the following <Attributes> child nodes:
XML Element Value
Data Type
Description
id
Integer
Identifies the unique identifier for the comment most recently added.
DOC_ID
Integer
Identifies the document IDs for the comment recently added.
USER_ID
Integer
Identifies the ID of the person who submitted the comment.
USER_NAME
String
Identifies the user name of the person who submitted the comment.
EMAIL_ADDRESS
String
Identifies the email address of the person who submitted the comment.
COMMENT_TEXT
String
Identifies the text for the comment recently added.
COMMENT_TIMESTAMP
Date
Identifies the date and time the comment was added.
 
getDecisionTrees
The following parameters apply to the getDecisionTrees method:
Parameter
Type
Description
SID
Integer
Identifies the session retrieved from logging in.
propertyList
String
Identifies the comma-separated list of database fields for which you want to retrieve information. The following fields are always returned, regardless of the propertyList parameter:
id
DOC_TYPE_ID
BU_RESULT
sortBy
String
Identifies the database field that you want to use for sorting the results. The default is id. Multiple sort fields are not supported.
If you specify another field, id as a secondary sort always sorts the results.
descending
Boolean
Identifies an indicator available for sorting the results in descending order.
Description
Retrieves all Decision Trees. Decision trees are Knowledge Documents that provide users with resolutions after answering specific questions on the document.
Returns
A <UDSObjectList> node with the following sections:
<UDSObject> nodes with requested <Attributes> nodes
getDocument
The following parameters apply to the getDocument method:
Parameter
Type
Description
SID
Integer
Identifies the session retrieved from logging in.
docId
Integer
Identifies the document ID to retrieve.
propertyList
String
Identifies the comma-separated list of database fields from which you want to retrieve information. Leave blank to retrieve all fields.
relatedDoc
Boolean
Indicates whether to retrieve a list of documents that are related to this document.
getAttmnt
Boolean
Indicates whether to retrieve the list of attachments and URL links for the document.
getHistory
Boolean
Indicates whether you want to retrieve the complete history for the document.
getComment
Boolean
Indicates whether you want to retrieve all comments for the document.
getNotiList
Boolean
Indicates whether you want to retrieve the email notification list for the document.
Description
Retrieves information for a document.
Returns
A <UDSObject> node, as described in the <UDSObject> Node Description, with requested <Attributes> provided by the propertList parameter.
getDocumentsByIDs
The following parameters apply to the getDocumentsByIDs method:
Parameter
Type
Description
SID
Integer
Identifies the session retrieved from logging in.
docIds
String
Identifies the comma-separated list of document IDs to retrieve.
propertyList
String
Identifies the comma-separated list of database fields for which you want to retrieve information. The following fields are always returned, regardless of the propertyList parameter:
id
DOC_TYPE_ID
BU_RESULT
sort By
String
Identifies the database field that you want to use for sorting the results. The default is id, but multiple sort fields are not supported. If you specify another field, id as a secondary sort always sorts the results.
descending
Boolean
Identifies an indicator available for sorting the results in descending order.
Description
Retrieves information on one or more documents by passing the document IDs for which you want to retrieve information. This is usually used after calling the faq() or search() methods. In order to improve performance, these methods only retrieve detailed information on a user-defined set of documents. The rest of the documents return their IDs only. For example, you can set up a paging mechanism, where the user can click on Top, Previous, Next, and Bottom links. When you need to retrieve the next set of information, you can use the getDocumentsByIDs() method.
Returns
A <UDSObjectList> node with the following section:
<UDSObject> nodes with requested <Attributes> nodes describing Knowledge Document
You should pass the IDs into the getDocumentsByIDs() docIds parameter in this same format.
getBopsid
The following parameters apply to the getBopsid method:
Parameter
Type
Description
SID
Integer
Identifies the session retrieved from logging in.
contact
String
Identifies the name of the user associated with the returned BOPSID.
Note:
This is the system login name, not the CA SDM contact name.
Description
Facilitate the building of Web Interface URLs, which may be used to launch the Web Interface in the context of a given user without a login challenge. The URL may look similar to the following:
http://host/CAisd/pdmweb.exe?BOPSID=nnnnn+OP=xxxx...
To launch the Web Interface in the context of a given user (for example, an analyst), a calling application must first construct a Web Interface URL, which includes a BOPSID token (a web-interface security token). Failure to provide a BOPSID token may result in an interactive login challenge when attempting to launch the Web Interface in the chosen context (such as, a detail view of a given ticket). The getBopsid method allows the BOPSID to be generated in the context of the user provided by the Name parameter. If the Name parameter is not provided, it uses the user associated with the current Web Interface BOPSID.
To prevent unauthorized elevation of privileges, the BOPSID of the current login must have equal or greater access rights than the name of the user entered.
Returns
A BOPSID based on the name of the user entered. You must use the BOPSID to launch the Web Interface within 30 seconds of it being generated.
The BOPSID of the current login must have equal or greater access rights than the name of the user entered.
getConfigurationMode
The following parameters apply to the getConfigurationMode method:
Parameter
Type
Description
SID
Integer
Identifies the SID of the current login session.
Description
This method returns a string indicating if the CA SDM installation is in the ITIL mode.
Returns
A string "itil" if the installation is in ITIL mode. Otherwise, an empty string is returned.
getObjectValues
The following parameters apply to the getObjectValues method:
Parameter
Type
Description
SID
Integer
Identifies the session retrieved from logging in.
objectHandle
String
Identifies the handle of a CA SDM object to query.
attributes
String[]
Identifies the names of attributes to fetch. If this field is empty, all the attributes for the object are returned.
Note:
Dot-names for attributes are only supported for SREL type attributes, and not for LREL/BREL/QREL type attributes.
Description
This method returns the attribute values of an object. The caller passes one or more attribute names to fetch the object and dotted-names are permitted.
All values are returned as a string. Empty/null attributes are returned as empty strings.
Returns
A <UDSObject> element.
XML Element
Type
Description
<UDSObject>
N/A
Contains a <Handle> element and zero or more <AttributeNameX> elements.
 
getObjectTypeInformation
The following parameters apply to the getObjectTypeInformation method:
Parameter
Type
Description
SID
Integer
Identifies the session retrieved from logging in.
factory
String
Identifies the object type (known as ‘factory’) to query. This is the majic name of the object, for example:
“cr” = Request
Description
A list of all attribute names for a given object type, along with type information for each attribute. Information returned for the attribute’s type includes the Integer, String, Date, Pointer, List, and so on, if the attribute is required for back-storing its storage space requirements (if appropriate).
Callers should cache the type information requested per object type to avoid multiple, redundant (and expensive) calls. The attribute information can change only after modifications are performed on the CA SDM server and the service is recycled.
Returns
The following:
XML Element
Type
Description
<UDSObject>
N/A
Indicates the root node.
<Attributes>
Sequence
Indicates zero or more elements for each attribute.
<attrName DataType=”dataType” Size=”storageSize” Required=”Boolean” Factory=”factoryName”>
EmptyElement
Indicates an element with a name matching an object attribute name. The element has several attributes:
DataType
Signifies the integer representation of the data type.
Size
Represents the maximum size needed to store this attribute in a string.
Required
Represents the flag status of True if this attribute must be set for the object to back store.
Factory
Represents the Type name of the object if the attribute is a List, Lrel or Pointer type. It is not written unless it is a Llist, Lrel, or Pointer type data type.
 
getArtifact
The following parameters apply to the getArtifact method:
Parameter
Type
Description
SID
Integer
Identifies the session retrieved from logging in.
contact
String
Identifies the name of the user associated with the returned ARTIFACT.
Note:
This is the system login name, not the contact name for CA Service Desk Manager.
password
String
Identifies the password.
Description
Facilitates the building of Web Interface URLs, which may be used to launch the Web Interface in the context of a given user without a login challenge. The URL may look similar to the following:
http://host/CAisd/pdmweb.exe?USERNAME=xxxxx+ARTIFACT=nnnnn+OP=xxxx....
To launch the Web Interface in the context of a given user (for example, an analyst), a calling application must first construct a Web Interface URL, which includes an CA EEM ARTIFACT token (a web-interface security token). Failure to provide a CA EEM ARTIFACT token may result in an interactive login challenge when attempting to launch the Web Interface in the chosen context (such as, a detail view of a given ticket). The getArtifact method allows the CA EEM ARTIFACT to be generated in the context of the user provided by the contact parameter.
Service Desk needs to be integrated with CA EEM to perform this operation.
Returns
An CA EEM ARTIFACT based on the name of the user entered. You can use the ARTIFACT to launch the Web Interface only once.