Note
Kailangan ng pahintulot para ma-access ang page na ito. Maaari mong subukang mag-sign in o magpalit ng mga direktoryo.
Ang pag-access sa pahinang ito ay nangangailangan ng pahintulot. Maaari mong subukang baguhin ang mga direktoryo.
Sends updated app context to the Microsoft Copilot side panel.
Syntax
Xrm.Copilot.updateContext(context).then(successCallback, errorCallback);
Parameters
| Parameter Name | Type | Required | Description |
|---|---|---|---|
context |
PowerAppsContent | Yes | An object describing the current app context to send to the Microsoft Copilot side panel. |
successCallback |
Function | Yes | A function to call when the operation succeeds. |
errorCallback |
Function | Yes | A function to call when the operation fails. |
Return Value
Type: Promise<void>
Remarks
The API automatically merges base context fields (appId, appType, orgId, geo, schemaVersion). You don't need to provide these fields. The API does nothing if Microsoft Copilot isn't enabled. Agents you author can't yet use context to optimize their responses.
Example
await Xrm.Copilot.updateContext({
entity: "account",
filterXML: "<fetch><entity name='account'><filter><condition attribute='statecode' operator='eq' value='0'/></filter></entity></fetch>"
});