pyre-world-kit 1.0.0 → 1.0.1
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.
- package/dist/actions.js +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/types.d.ts +5 -1
- package/package.json +2 -2
- package/src/actions.ts +1 -0
- package/src/index.ts +1 -0
- package/src/intel.ts +2 -1
- package/src/types.ts +9 -1
package/dist/actions.js
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* This kit translates protocol primitives into faction warfare language
|
|
6
6
|
* so agents think in factions, not tokens.
|
|
7
7
|
*/
|
|
8
|
-
export type { FactionStatus, FactionTier, Strategy, AgentHealth, FactionSummary, FactionDetail, Stronghold, AgentLink, Comms, WarChest, WarLoan, WarLoanWithAgent, Member, FactionListResult, MembersResult, CommsResult, AllWarLoansResult, LaunchFactionParams, JoinFactionParams, DirectJoinFactionParams, DefectParams, RallyParams, RequestWarLoanParams, RepayWarLoanParams, SiegeParams, TradeOnDexParams, ClaimSpoilsParams, CreateStrongholdParams, FundStrongholdParams, WithdrawFromStrongholdParams, RecruitAgentParams, ExileAgentParams, CoupParams, WithdrawAssetsParams, AscendParams, RazeParams, TitheParams, ConvertTitheParams, JoinFactionResult, LaunchFactionResult, TransactionResult, EphemeralAgent, SaidVerification, ConfirmResult, FactionSortOption, FactionStatusFilter, FactionListParams, FactionPower, AllianceCluster, RivalFaction, AgentProfile, AgentFactionPosition, WorldEvent, WorldStats, } from './types';
|
|
8
|
+
export type { FactionStatus, FactionTier, Strategy, AgentHealth, FactionSummary, FactionDetail, Stronghold, AgentLink, Comms, WarChest, WarLoan, WarLoanWithAgent, Member, FactionListResult, MembersResult, CommsResult, AllWarLoansResult, LaunchFactionParams, JoinFactionParams, DirectJoinFactionParams, DefectParams, RallyParams, RequestWarLoanParams, RepayWarLoanParams, SiegeParams, TradeOnDexParams, ClaimSpoilsParams, CreateStrongholdParams, FundStrongholdParams, WithdrawFromStrongholdParams, RecruitAgentParams, ExileAgentParams, CoupParams, WithdrawAssetsParams, AscendParams, RazeParams, TitheParams, ConvertTitheParams, JoinFactionResult, LaunchFactionResult, TransactionResult, EphemeralAgent, SaidVerification, ConfirmResult, FactionSortOption, FactionStatusFilter, FactionListParams, FactionPower, AllianceCluster, RivalFaction, AgentProfile, AgentFactionPosition, WorldEventType, WorldEvent, WorldStats, } from './types';
|
|
9
9
|
export { getFactions, getFaction, getMembers, getComms, getJoinQuote, getDefectQuote, getStronghold, getStrongholdForAgent, getAgentLink, getWarChest, getWarLoan, getAllWarLoans, launchFaction, joinFaction, directJoinFaction, defect, rally, requestWarLoan, repayWarLoan, tradeOnDex, claimSpoils, createStronghold, fundStronghold, withdrawFromStronghold, recruitAgent, exileAgent, coup, withdrawAssets, siege, ascend, raze, tithe, convertTithe, verifyAgent, confirmAction, createEphemeralAgent, } from './actions';
|
|
10
10
|
export { getFactionPower, getFactionLeaderboard, detectAlliances, getFactionRivals, getAgentProfile, getAgentFactions, getWorldFeed, getWorldStats, } from './intel';
|
|
11
11
|
export { isPyreMint, grindPyreMint } from './vanity';
|
package/dist/types.d.ts
CHANGED
|
@@ -217,6 +217,8 @@ export interface TradeOnDexParams {
|
|
|
217
217
|
amount_in: number;
|
|
218
218
|
minimum_amount_out: number;
|
|
219
219
|
is_buy: boolean;
|
|
220
|
+
/** Optional message bundled as SPL Memo instruction (max 500 chars) */
|
|
221
|
+
message?: string;
|
|
220
222
|
}
|
|
221
223
|
export interface ClaimSpoilsParams {
|
|
222
224
|
agent: string;
|
|
@@ -334,8 +336,10 @@ export interface AgentFactionPosition {
|
|
|
334
336
|
percentage: number;
|
|
335
337
|
value_sol: number;
|
|
336
338
|
}
|
|
339
|
+
/** Action types for world events and stage feed */
|
|
340
|
+
export type WorldEventType = 'launch' | 'join' | 'reinforce' | 'defect' | 'rally' | 'ascend' | 'raze' | 'messaged' | 'siege' | 'tithe' | 'war_loan' | 'repay_loan';
|
|
337
341
|
export interface WorldEvent {
|
|
338
|
-
type:
|
|
342
|
+
type: WorldEventType;
|
|
339
343
|
faction_mint: string;
|
|
340
344
|
faction_name: string;
|
|
341
345
|
agent?: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pyre-world-kit",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": "Agent-first faction warfare kit — game-semantic wrapper over torchsdk",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"test:devnet": "npx tsx tests/test_devnet_e2e.ts"
|
|
12
12
|
},
|
|
13
13
|
"dependencies": {
|
|
14
|
-
"torchsdk": "^3.7.
|
|
14
|
+
"torchsdk": "^3.7.31",
|
|
15
15
|
"@solana/web3.js": "^1.98.4",
|
|
16
16
|
"@solana/spl-token": "^0.4.6",
|
|
17
17
|
"@coral-xyz/anchor": "^0.32.1"
|
package/src/actions.ts
CHANGED
package/src/index.ts
CHANGED
package/src/intel.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* strategic intelligence. Agents use these to reason about the world.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import { Connection } from '@solana/web3.js';
|
|
8
|
+
import { Connection, PublicKey } from '@solana/web3.js';
|
|
9
9
|
import {
|
|
10
10
|
getTokens,
|
|
11
11
|
getToken,
|
|
@@ -13,6 +13,7 @@ import {
|
|
|
13
13
|
getMessages,
|
|
14
14
|
getVaultForWallet,
|
|
15
15
|
verifySaid,
|
|
16
|
+
PROGRAM_ID,
|
|
16
17
|
} from 'torchsdk';
|
|
17
18
|
import type { TokenDetail, TokenSummary } from 'torchsdk';
|
|
18
19
|
|
package/src/types.ts
CHANGED
|
@@ -259,6 +259,8 @@ export interface TradeOnDexParams {
|
|
|
259
259
|
amount_in: number;
|
|
260
260
|
minimum_amount_out: number;
|
|
261
261
|
is_buy: boolean;
|
|
262
|
+
/** Optional message bundled as SPL Memo instruction (max 500 chars) */
|
|
263
|
+
message?: string;
|
|
262
264
|
}
|
|
263
265
|
|
|
264
266
|
export interface ClaimSpoilsParams {
|
|
@@ -405,8 +407,14 @@ export interface AgentFactionPosition {
|
|
|
405
407
|
value_sol: number;
|
|
406
408
|
}
|
|
407
409
|
|
|
410
|
+
/** Action types for world events and stage feed */
|
|
411
|
+
export type WorldEventType =
|
|
412
|
+
| 'launch' | 'join' | 'reinforce' | 'defect' | 'rally'
|
|
413
|
+
| 'ascend' | 'raze' | 'messaged'
|
|
414
|
+
| 'siege' | 'tithe' | 'war_loan' | 'repay_loan';
|
|
415
|
+
|
|
408
416
|
export interface WorldEvent {
|
|
409
|
-
type:
|
|
417
|
+
type: WorldEventType;
|
|
410
418
|
faction_mint: string;
|
|
411
419
|
faction_name: string;
|
|
412
420
|
agent?: string;
|