Skip to main content

String Resources

In Aprimo Productivty Management, picklist and multiselect values are represented as key/resourceId pairs, with the resourceId enabling string lookup.

Types of Strings

  1. Static Strings: Built into the product (e.g., time zones, currency codes).
    • Identified by mo-replacement-strings-X, where X is an integer.
  2. Dynamic Strings: Created for your tenant through configuration (e.g., extended attribute picklist options, system type values).
    • Identified by mo-encoded-titles-X, where X is an integer.

Looking up String Picklists & Multiselects

Example: Timezone

When retrieving a record with a timezone in the API, you'll receive an integer ID (e.g., "timeZoneId": 43). Use lookup endpoints to find the corresponding string value.

Methods for String Lookup

1. Look Up All Static Strings

  • Use GET /api/resources/static to retrieve all static strings (mo-replacement-strings-X).
  • Recommendation: Cache the response and refresh periodically, as static strings rarely change.

2. Look Up a Single String

  • Use GET /api/resources/{resourceId} to retrieve the value of a specific string.
  • Example:
  {
"id": "mo-replacement-strings-848894",
"value": "(GMT-05:00) Eastern Time (US & Canada)",
"_links": {
"self": {
"href": "resources/mo-replacement-strings-848894",
"type": "application/vnd.td-apps.operations.resources"
}
}
}

Use these endpoints to query and understand string values associated with picklist or multiselect options in API responses

Querying for Strings

To look up multiple strings at once, use the POST /api/resources/query endpoint. Include a JSON body with a query property containing a comma-separated list of resourceId values. This endpoint supports both static and dynamic strings.

Request Example

POST Body:

{
"query": "mo-replacement-strings-848894,mo-encoded-titles-911832"
}

Headers: Content-Type: application/json

Response Examples

{
"resources": [
{
"id": "mo-replacement-strings-848894",
"value": "(GMT-05:00) Eastern Time (US & Canada)"
},
{
"id": "mo-encoded-titles-911832",
"value": "Integrated Activity"
}
]
}

This method allows efficient lookup for multiple strings in a single call. Dynamic string IDs are environment-specific and may vary in your instance.