@tari-project/tarijs-builders 0.5.4 → 0.5.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import { ComponentAddress, ConfidentialClaim, ConfidentialWithdrawProof, Instruction, ResourceAddress, SubstateRequirement, Transaction, TransactionSignature, UnsignedTransaction, PublishedTemplateAddress, TransactionArg } from "@tari-project/tarijs-types";
1
+ import { ComponentAddress, ConfidentialClaim, ConfidentialWithdrawProof, Instruction, ResourceAddress, SubstateRequirement, Transaction, TransactionSignature, UnsignedTransaction, PublishedTemplateAddress, SubstateType, TransactionArg } from "@tari-project/tarijs-types";
2
2
  export interface TransactionConstructor {
3
3
  new (unsignedTransaction: UnsignedTransaction, signatures: TransactionSignature[]): Transaction;
4
4
  }
@@ -51,6 +51,7 @@ export declare class TransactionBuilder implements Builder {
51
51
  createAccount(ownerPublicKey: string, workspaceBucket?: string): this;
52
52
  createProof(account: ComponentAddress, resourceAddress: ResourceAddress): this;
53
53
  claimBurn(claim: ConfidentialClaim): this;
54
+ allocateAddress(substateType: SubstateType, workspaceId: string): this;
54
55
  /**
55
56
  * The `SaveVar` method replaces
56
57
  * `PutLastInstructionOutputOnWorkspace: { key: Array<number> }`
@@ -58,6 +58,14 @@ export class TransactionBuilder {
58
58
  },
59
59
  });
60
60
  }
61
+ allocateAddress(substateType, workspaceId) {
62
+ return this.addInstruction({
63
+ AllocateAddress: {
64
+ substate_type: substateType,
65
+ workspace_id: workspaceId,
66
+ },
67
+ });
68
+ }
61
69
  /**
62
70
  * The `SaveVar` method replaces
63
71
  * `PutLastInstructionOutputOnWorkspace: { key: Array<number> }`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tari-project/tarijs-builders",
3
- "version": "0.5.4",
3
+ "version": "0.5.5",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "publishConfig": {
@@ -11,8 +11,8 @@
11
11
  "license": "ISC",
12
12
  "dependencies": {
13
13
  "@tari-project/tari-signer": "^0.5.3",
14
- "@tari-project/tarijs-types": "^0.5.4",
15
- "@tari-project/tari-universe-signer": "^0.5.4"
14
+ "@tari-project/tari-universe-signer": "^0.5.5",
15
+ "@tari-project/tarijs-types": "^0.5.5"
16
16
  },
17
17
  "devDependencies": {
18
18
  "@types/node": "^22.13.1",