Is the Management-Canister blocked from https calls from the outside? How to create a canister with an agent from the outside?

I have it with the correct parameters.
The steps for the creation of a canister with an agent talking to the ledger are as follows:

  1. Get the the caller(future-canister-controller)'s-principal as a 32byte subaccount using this function here.

  2. Create an icp account-identifier using this function here, with the cycles-mint-canister-principal and with the subaccount-bytes as the subaccount-bytes of the step-1.

  3. Call the send_dfx method with the ‘to’-field as the icp-account-identifier of the step-2, with the ‘memo’ field as a Nat64: 1095062083 (this is the create-canister-memo) , and save the block-height.

  4. Call the notify_dfx method on the ledger-canister with the block-height of the step-3, with the ‘to_canister’ field as a Blob of the cycles-mint-canister-principal, with the ‘to_subaccount’ field as an option with a value of a Blob of the subaccount-bytes of the step-1.

  5. Step-4 should give back this Variant here :

variant {
  Refunded : record { text; opt nat64 };
  CanisterCreated : principal;
  ToppedUp;
};

And if everything goes well then a new-canister-id will be in the CanisterCreated field as a candid-principal-reference.

Also the caller must have sufficient icp.

Here is a link to the management-canister-effective-canister-id-post above in this thread because I can’t mark a post as a partial-answer.

Also, each ledger .did file Ive seen shows the notify_dfx method as taking a record with the field: ‘to_canister’ as a principal-reference-type, but in the fact it is a blob-type.

:pray:t4:

3 Likes