6

I'm interacting with stellar-core alone without any SDK/Horizon support. I've created a private network with 5 nodes, each a validator node requiring 2/3 of the 5 nodes to agree.

I'm a bit confused as to how account creation works. The documentation doesn't really touch on how accounts are created without SDK support. I'm assuming the account information is a just a public key correlated with the private keys thats held by the account owner, and I'm further assuming that an account gets registered with one peer and that peer sends this account creation operation to the network for consensus, it is then stored somewhere on all the peers.

My questions is, are my assumptions true? And how exactly do I create an account (i.e. what commands do I need and how do I use that command)?


UPDATE: I managed to create a transaction containing a createAccount operation through stellar-lab and I tried submitting the transaction using the command --c \tx?blob=BASED64, but I'm getting the error GBVQ6 [default INFO] {"status": "ERROR" , "error": "AAAAAAAAAAD////3AAAAAA=="}

1 Answer 1

2

Your assumptions are correct.

Accounts are created by submitting a signed transaction to the network, a transaction containing a createAccount operation.

https://www.stellar.org/developers/guides/concepts/list-of-operations.html#create-account

https://www.stellar.org/developers/js-stellar-base/reference/base-examples.html#creating-an-account

6
  • I saw that but my question was how to send a transaction containing a createAccount operation without SDK support. i.e. using nothing but stellar-core
    – B.Li
    Oct 3, 2018 at 0:41
  • You can't. You have to generate the XDR blob somehow. That's done by the SDK. Oct 3, 2018 at 0:56
  • Sending it isn't complicated, that's just the /tx?blob={base-64 blocb} endpoint of your stellar-core node Oct 3, 2018 at 0:57
  • Do you mean that as a statement about the transaction's reply message? As in one can send a transaction via /tx endpoint but not necessarily receive any useful information about it?
    – B.Li
    Oct 3, 2018 at 18:08
  • It's an asynchronous interface. It tells you if it's a transaction already submitted, or if there's an error with it. If you want better sending support, that's Horizon. Oct 4, 2018 at 1:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.