Waiting for engine...
Skip to main content

Atom Map Extension functions (Deprecated)

You can use the Atom Map Extension object, now deprecated, to retrieve or update map functions. Map functions allow transformation logic to be applied to individual field values as they are being mapped. 

CAUTION:
The Atom Map Extension object is a deprecated API and should no longer be used. removed non-environment functionality from the , and all accounts changed to utilize Environments. Therefore, Boomi recommends that you take advantage of the API functionality provided by the Environment Map Extensions object instead. For more information about 's API object deprecation status, refer to the topic API deprecation and versioning policy.

Supported function types

The GET, UPDATE, and EXECUTE operations all support the <Function> element's type attribute. For UPDATE requests, specify the function type in the request body. For GET and EXECUTE requests, it returns the function type in the response.

Most function types are valid for GET, UPDATE, and EXECUTE operations. However, the following function types are not valid for these API operations. As a result, extensible maps that contain these values cannot be retrieved or updated from the API.

  • SQL Lookup

  • Connector Call

  • Document Cache Lookup

  • Get Process Property

  • Set Process Property

  • Set Trading Partner

Extending map functions with the UPDATE operation

Most map functions that are valid in the UI for applying transformation logic to mappings can be extended with the UPDATE operation. Each function input and output has a numeric key attribute. For a given function, the first input or output has a key attribute value of 1, the second a key attribute value of 2, and so on. (For functions with variable outputs — String Split and Custom Scripting — key assignments may vary.)

For example, consider the function StringAppend, which is used to add characters to the end of a string value. The function’s input and output values are strings, and the function has the following input parameters:

  • Fix to Length (optional) — integer specifying the length of the output

  • Char to Append — character string to append

The portion of the UPDATE request structure by which the function is extended is as follows:

<ExtendedFunctions>
...
<bns:Function type="StringAppend" id="" cacheType="ByDocument">
<bns:Inputs>
<bns:Input key="1" name="Original String" default=""/>
<bns:Input key="2" name="Fix to Length" default=""/>
<bns:Input key="3" name="Char to Append" default=""/>
</bns:Inputs>
<bns:Outputs>
<bns:Output key="1" name="Result"/>
</bns:Outputs>
<bns:Configuration/>
</bns:Function>
...
</ExtendedFunctions>

The <Function> element’s id attribute value is an arbitrary unique string.

To extend the following functions, it is necessary to populate the <Configuration> element:

  • CustomScripting

  • DocumentPropertyGet

  • DocumentPropertySet

  • StringConcat

  • StringSplit

  • SequentialValue

  • SimpleLookup

To complete the configuration of an extended function, the UPDATE operation must do the following:

  • Map an element in the source profile to each function input value.

  • Map the function output value, Result, to an element in the destination profile.

Profile elements are specified by XPath.

Returning to the StringAppend example, the portion of the UPDATE request structure by which these mappings are specified is as follows:

<ExtendedMappings>
...
<bns:Mapping toFunction="" fromXPath="" toXPath="1"/>
<bns:Mapping fromFunction="" fromXPath="1" toXPath=""/>
...
</ExtendedMappings>

In these mappings, the toFunction and fromFunction attribute values must be the same as the id attribute value assigned to the corresponding <Function> element. When reusing a profile previously browsed for using a GET or EXECUTE operation, you can use the session ID returned from that operation, if available, in the UPDATE request in lieu of credentials. For about 30 minutes, the platform binds a browsed profile with the remote connection session ID.

The <SourceProfileExtensions> and <DestinationProfileExtensions> elements specify the structure of the extended source and destination profiles. The markup syntax is consistent with that of the source and destination profiles in the underlying process.

You can omit the <SourceProfile> and <DestinationProfile> elements from the UPDATE request, as those elements are included in the Atom Map Extension object structure merely for reference.

CAUTION:
The platform removes mappings and functions omitted from the UPDATE request. To prevent removal of mappings and functions, include in the request all mappings and functions as returned by a GET operation, including those you are not changing. This caution does not apply to profiles — source, destination, and profile extensions are not used in updates.

On this Page