Request
request(
options
):Promise
<StatusMap
>
Defined in: packages/agent/src/canisterStatus/index.ts:141
Request information in the request_status state tree for a given canister. Can be used to request information about the canister’s controllers, time, module hash, candid interface, and more.
Parameters
Section titled “Parameters”options
Section titled “options”HttpAgent optional authenticated agent to use to make the canister request. Useful for accessing private metadata under icp:private
canisterId
Section titled “canisterId”paths?
Section titled “paths?”Returns
Section titled “Returns”Promise
<StatusMap
>
object populated with data from the requested paths
Example
Section titled “Example”const status = await canisterStatus({ paths: ['controllers', 'candid'], ...options});
const controllers = status.get('controllers');