system_import_account
Import accounts into the local keystore for use with NEAR MCP tools. Supports mainnet and testnet accounts, enabling access via private key or JSON file import.
Instructions
Import an account into the local keystore. This will allow the user to use this account with other tools. Remember mainnet accounts are created with a .near suffix, and testnet accounts are created with a .testnet suffix.
Input Schema
Name | Required | Description | Default |
---|---|---|---|
args | Yes |
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"args": {
"anyOf": [
{
"additionalProperties": false,
"properties": {
"accountId": {
"type": "string"
},
"networkId": {
"default": "mainnet",
"enum": [
"testnet",
"mainnet"
],
"type": "string"
},
"op": {
"const": "import_from_private_key",
"type": "string"
},
"privateKey": {
"description": "The private key for the account. If provided, this will be used to import the account.",
"type": "string"
}
},
"required": [
"op",
"accountId",
"privateKey"
],
"type": "object"
},
{
"additionalProperties": false,
"properties": {
"filePath": {
"description": "\nThe path to the file containing the account id, public key, and private key.\nThe file should be in JSON format and the filename should be something\nlike `<accountId>.<networkId>.json`.",
"type": "string"
},
"op": {
"const": "import_from_file",
"type": "string"
}
},
"required": [
"op",
"filePath"
],
"type": "object"
}
]
}
},
"required": [
"args"
],
"type": "object"
}