pm_createPolicy

📘

Supported on both Mainnet and Testnet.

Endpoint

  • Mainnet: https://open-platform-ap.nodereal.io/{apikey}/megafuel
  • Testnet: https://open-platform-ap.nodereal.io/{apikey}/megafuel-testnet

The {apikey} should be created via Nodereal MegaNode. Please refer to Sponsor Guidelines.

Create a new sponsor policy. The caller's MegaNode identity (derived from the api-key) is automatically set as the policy owner.

Notes:

  • maxGasCost is always initialised to 0 at creation time. Fund the policy afterwards via the deposit API.
  • Each sponsor may own at most N policies (default 5, configurable by the platform).
Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
string
required
Defaults to <your-nodereal-apikey>
Body Params
integer
Defaults to 1
string
Defaults to 2.0
string
enum
Defaults to pm_createPolicy
Allowed:
params
array of objects
length between 1 and 1
Defaults to [object Object]
params
string
required

Policy name. Must be non-empty and at most 64 characters.

integer
required

Chain ID of the network this policy applies to (e.g. 56 for BSC mainnet, 97 for BSC testnet).

integer
required

Policy type. Refer to platform documentation for supported values.

string

Maximum total gas cost (in wei) that can be sponsored for a single address over the policy lifetime.
Omit or pass "" for no limit.

string

Maximum gas cost (in wei) that can be sponsored for a single address per day.
Omit or pass "" for no limit.

string
required

Minimum transaction value (in wei) required for sponsorship eligibility. Must be a non-negative integer string. Use "0" for no minimum.

string

Maximum number of transactions that can be sponsored for a single address per day.
Omit or pass "" for no limit.

int64
required

Unix timestamp (seconds) when the policy becomes active. Must be less than end.

int64
required

Unix timestamp (seconds) when the policy expires. Must be greater than start.

string

Display name of the sponsor. Max 64 characters. Optional.

string

URL of the sponsor's icon. Max 2048 characters. Optional.

string

URL of the sponsor's website. Max 2048 characters. Optional.

string

Optional. The on-chain address from which BNB transfers to the platform wallet are automatically
credited to this policy (Type-2 auto-deposit). Must be a valid hex address.
Omit or pass null to leave unset.

string

Short description of the policy. Max 200 characters. Optional.

string

Telegram contact for the sponsor. Max 200 characters. Optional.

string

Phone contact for the sponsor. Max 200 characters. Optional.

Response

Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json