call

Calls a contract off-chain and returns the execution result.

Parameters

1. invocation (required)

InvocationArguments

type InvocationArguments = {
  hash: UInt160;
  operation: string;
  args?: Argument[];
  abortOnFail?: boolean;
};

Returns

Promise<InvocationResult>

type InvocationResult = {
  script: Base64Encoded;
  state: VMState;
  gasconsumed: Integer;
  exception?: string;
  notifications: Notification[];
  stack: StackItem[];
};

Errors

Code
Name
Description

10002

INVALID

One or more inputs are invalid.

10008

RPC_ERROR

The RPC server returned an error.

Example

Request

Response

最后更新于