Service: Resources

Resource-related functions and objects

Functions

ResultName / ParamsComment
ResourceResultext.resource.GetRequests a resource from the host. Note that the resource may only be accessible temporarily; for instance immediately after an Operation containing the resource URL was received from the host.
urlstring(Value: AopUrl) Resource URL.
propsvalue{}(Optional, Key: Symbol) Additional properties required to get the resource.
voidext.resource.PutSends a resource to the host. The definition of the resource with this URL must be known at the host and has to be provided previously, e.g., in the context of an Object Event. If the resource value is very large (e.g., > 1 MB), consider using out-of-band HTTP transfer instead.
urlstring(Value: AopUrl) Resource URL.
valuevalueThe resource value.

Objects

Resource

Property Type Description
Method string The resource transfer method. See ResourceTransferMethod.
Type string Data type of resource: ‘bool’, ‘int’, ‘float’, ‘string’, ‘guid’, ’time’, ‘data’ or ‘object’; optionally with [] suffix to declare an array. String and data resources are most common.
Kind string (Optional) Explanation with regard to type, mostly for resources of type ‘data’, e.g., ‘image/jpeg’.
Url string (Value: AopUrl) URL of the resource. Extension origin must match the Extension code of the providing Extension.
Props value{} (Key: Symbol, Optional) Additional information required for the query (e.g., Badge Id). This information is passed to the resource.Get function if Method is ‘get’.

ResourceResult

Result of a resource.Get call. Only exactly one of Url, Value or Error may be set.

Property Type Description
Url string (Optional) Transfer URL for out-of-band HTTP data transfer.
Value value (Optional) The resource value.
Error string (Optional) Contains a string error Id to indicate a failure. In this case, Props can contain further information with regard to the error.
Props value{} (Key: Symbol, Optional) Additional information for a successful result, or details with regard to the error.

Enums

ResourceTransferMethod

Name Value Description
Get get Resource can be queried via resource.Get.
Put put Resource is pushed to server by the Extension at an unspecified time.
Last modified September 25, 2026