Skip to content

@my-swu/simulator-client


@my-swu/simulator-client / DeckInput

Type Alias: DeckInput

DeckInput = CreateMatchRequest["hostDeck"]

Defined in: packages/ts-sdk/src/resources/card-types.ts:55

Deck payload accepted by match creation and join calls.

The same shape is used for Premier, Eternal, Trilogy, Draft, Sealed, Twin Suns, and AI opponent decks. The server validates format-specific legality when the deck is submitted.

Example:

ts
import type { 
DeckInput
} from '@my-swu/simulator-client'
const
deckInput
:
DeckInput
= {
leader
: 60,
base
: 95,
cards
:
Array
.
from
({
length
: 50 }, () => 45),
}
console
.
log
(
deckInput
)

Example

ts
import type { DeckInput } from '@my-swu/simulator-client'

const premierDeck: DeckInput = {
  leader: 46102,
  base: 308,
  cards: Array.from({ length: 50 }, () => 45),
}

console.log(premierDeck.cards.length)

See

https://simulator-sdk.my-swu.com/guide/deckbuilding-formats

Released under the MIT License.