create_node

ManagedBlockchain.Client.create_node(**kwargs)

Creates a node on the specified blockchain network.

Applies to Hyperledger Fabric and Ethereum.

See also: AWS API Documentation

Request Syntax

response = client.create_node(
    ClientRequestToken='string',
    NetworkId='string',
    MemberId='string',
    NodeConfiguration={
        'InstanceType': 'string',
        'AvailabilityZone': 'string',
        'LogPublishingConfiguration': {
            'Fabric': {
                'ChaincodeLogs': {
                    'Cloudwatch': {
                        'Enabled': True|False
                    }
                },
                'PeerLogs': {
                    'Cloudwatch': {
                        'Enabled': True|False
                    }
                }
            }
        },
        'StateDB': 'LevelDB'|'CouchDB'
    },
    Tags={
        'string': 'string'
    }
)
Parameters
  • ClientRequestToken (string) --

    [REQUIRED]

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the operation. An idempotent operation completes no more than one time. This identifier is required only if you make a service request directly using an HTTP client. It is generated automatically if you use an Amazon Web Services SDK or the CLI.

    This field is autopopulated if not provided.

  • NetworkId (string) --

    [REQUIRED]

    The unique identifier of the network for the node.

    Ethereum public networks have the following NetworkId s:

    • n-ethereum-mainnet
    • n-ethereum-goerli
    • n-ethereum-rinkeby
    • n-ethereum-ropsten
  • MemberId (string) --

    The unique identifier of the member that owns this node.

    Applies only to Hyperledger Fabric.

  • NodeConfiguration (dict) --

    [REQUIRED]

    The properties of a node configuration.

    • InstanceType (string) -- [REQUIRED]

      The Amazon Managed Blockchain instance type for the node.

    • AvailabilityZone (string) --

      The Availability Zone in which the node exists. Required for Ethereum nodes.

    • LogPublishingConfiguration (dict) --

      Configuration properties for logging events associated with a peer node on a Hyperledger Fabric network on Managed Blockchain.

      • Fabric (dict) --

        Configuration properties for logging events associated with a node that is owned by a member of a Managed Blockchain network using the Hyperledger Fabric framework.

        • ChaincodeLogs (dict) --

          Configuration properties for logging events associated with chaincode execution on a peer node. Chaincode logs contain the results of instantiating, invoking, and querying the chaincode. A peer can run multiple instances of chaincode. When enabled, a log stream is created for all chaincodes, with an individual log stream for each chaincode.

          • Cloudwatch (dict) --

            Parameters for publishing logs to Amazon CloudWatch Logs.

            • Enabled (boolean) --

              Indicates whether logging is enabled.

        • PeerLogs (dict) --

          Configuration properties for a peer node log. Peer node logs contain messages generated when your client submits transaction proposals to peer nodes, requests to join channels, enrolls an admin peer, and lists the chaincode instances on a peer node.

          • Cloudwatch (dict) --

            Parameters for publishing logs to Amazon CloudWatch Logs.

            • Enabled (boolean) --

              Indicates whether logging is enabled.

    • StateDB (string) --

      The state database that the node uses. Values are LevelDB or CouchDB . When using an Amazon Managed Blockchain network with Hyperledger Fabric version 1.4 or later, the default is CouchDB .

      Applies only to Hyperledger Fabric.

  • Tags (dict) --

    Tags to assign to the node.

    Each tag consists of a key and an optional value. You can specify multiple key-value pairs in a single request with an overall maximum of 50 tags allowed per resource.

    For more information about tags, see Tagging Resources in the Amazon Managed Blockchain Ethereum Developer Guide , or Tagging Resources in the Amazon Managed Blockchain Hyperledger Fabric Developer Guide .

    • (string) --
      • (string) --
Return type

dict

Returns

Response Syntax

{
    'NodeId': 'string'
}

Response Structure

  • (dict) --

    • NodeId (string) --

      The unique identifier of the node.

Exceptions

  • ManagedBlockchain.Client.exceptions.InvalidRequestException
  • ManagedBlockchain.Client.exceptions.AccessDeniedException
  • ManagedBlockchain.Client.exceptions.ResourceNotFoundException
  • ManagedBlockchain.Client.exceptions.ResourceAlreadyExistsException
  • ManagedBlockchain.Client.exceptions.ResourceNotReadyException
  • ManagedBlockchain.Client.exceptions.ThrottlingException
  • ManagedBlockchain.Client.exceptions.ResourceLimitExceededException
  • ManagedBlockchain.Client.exceptions.InternalServiceErrorException
  • ManagedBlockchain.Client.exceptions.TooManyTagsException