# crafting
Documentation: 0.7.0 (source: v0.7.0).

Markdown source of https://docs-v0-7-0.atlas-kit-docs.pages.dev/reference/crafting/ — see https://docs-v0-7-0.atlas-kit-docs.pages.dev/ai/ for the full machine-readable surface.

## Interfaces

<a id="craftingbatchestimate"></a>

### CraftingBatchEstimate

Defined in: [packages/sage/src/crafting/estimate.ts:69](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L69)

What starting the batch would do, as the program computes it.

#### Example

```ts
declare const estimate: CraftingBatchEstimate;
console.log(estimate.durationSeconds, estimate.outputs, estimate.feeRaw);
```

#### Properties

<a id="crew"></a>

##### crew

```ts
readonly crew: number;
```

Defined in: [packages/sage/src/crafting/estimate.ts:72](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L72)

Crew the batch reserves from the StarbasePlayer.

<a id="crewroster"></a>

##### crewRoster

```ts
readonly crewRoster: "none" | "assumed";
```

Defined in: [packages/sage/src/crafting/estimate.ts:87](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L87)

<a id="durationseconds"></a>

##### durationSeconds

```ts
readonly durationSeconds: bigint;
```

Defined in: [packages/sage/src/crafting/estimate.ts:70](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L70)

<a id="feeraw"></a>

##### feeRaw

```ts
readonly feeRaw: bigint;
```

Defined in: [packages/sage/src/crafting/estimate.ts:86](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L86)

ATLAS fee escrowed from the Character, in Floyds.

<a id="ingredients"></a>

##### ingredients

```ts
readonly ingredients: readonly {
  amount: bigint;
  cargoId: number;
}[];
```

Defined in: [packages/sage/src/crafting/estimate.ts:76](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L76)

Ingredients debited at start, for the requested quantity.

<a id="outputs"></a>

##### outputs

```ts
readonly outputs: readonly {
  amount: bigint;
  cargoId: number;
}[];
```

Defined in: [packages/sage/src/crafting/estimate.ts:81](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L81)

Outputs credited at completion, for the process quantity.

<a id="processquantity"></a>

##### processQuantity

```ts
readonly processQuantity: bigint;
```

Defined in: [packages/sage/src/crafting/estimate.ts:74](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L74)

Crafts the Process completes: the requested quantity after efficiency.

#### Methods

<a id="tojson"></a>

##### toJSON()

```ts
toJSON(): unknown;
```

Defined in: [packages/sage/src/crafting/estimate.ts:88](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L88)

###### Returns

`unknown`

***

<a id="craftingbatchestimateinput"></a>

### CraftingBatchEstimateInput

Defined in: [packages/sage/src/crafting/estimate.ts:40](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L40)

A proposed crafting batch: a Recipe, how many crafts, the crew assigned,
an optional Crafting Hab, the Character's crafting modifiers, a crew-perk
assumption and the Starbase's crafting fee in basis points (10,000 leaves
the fee unchanged, as at a Starbase without governance).

#### Example

```ts
declare const recipe: RecipeSnapshot, character: CharacterSnapshot;
const input: CraftingBatchEstimateInput = {
  recipe, quantity: 10n, crew: 5, character: character.modifiers.values,
  crewRoster: { kind: 'none' }, craftingFeeBasisPoints: 10_000,
};
```

#### Properties

<a id="character"></a>

##### character

```ts
readonly character: {
  craftingEfficiencyModifierRaw: bigint;
  craftingTimeModifierRaw: bigint;
};
```

Defined in: [packages/sage/src/crafting/estimate.ts:54](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L54)

###### craftingEfficiencyModifierRaw

```ts
readonly craftingEfficiencyModifierRaw: bigint;
```

###### craftingTimeModifierRaw

```ts
readonly craftingTimeModifierRaw: bigint;
```

<a id="craftingfeebasispoints"></a>

##### craftingFeeBasisPoints

```ts
readonly craftingFeeBasisPoints: number;
```

Defined in: [packages/sage/src/crafting/estimate.ts:59](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L59)

<a id="crew-1"></a>

##### crew

```ts
readonly crew: number;
```

Defined in: [packages/sage/src/crafting/estimate.ts:52](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L52)

<a id="crewroster-1"></a>

##### crewRoster

```ts
readonly crewRoster: CraftingCrewAssumption;
```

Defined in: [packages/sage/src/crafting/estimate.ts:58](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L58)

<a id="hab"></a>

##### hab?

```ts
readonly optional hab?: {
  modifiers: CraftingModifierData;
};
```

Defined in: [packages/sage/src/crafting/estimate.ts:53](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L53)

###### modifiers

```ts
readonly modifiers: CraftingModifierData;
```

<a id="quantity"></a>

##### quantity

```ts
readonly quantity: bigint;
```

Defined in: [packages/sage/src/crafting/estimate.ts:51](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L51)

Crafts in the batch: each consumes one set of ingredients.

<a id="recipe"></a>

##### recipe

```ts
readonly recipe: Pick<RecipeSnapshot, 
  | "craftingDurationSeconds"
  | "minimumDurationSeconds"
  | "fee"
  | "habRequired"
  | "ingredients"
| "outputs">;
```

Defined in: [packages/sage/src/crafting/estimate.ts:41](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L41)

***

<a id="craftingcargoinventory"></a>

### CraftingCargoInventory

Defined in: [packages/sage/src/crafting/index.ts:79](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L79)

A registry-resolved nested crafting CargoPod.

#### Example

```ts
declare const inventory: CraftingCargoInventory;
console.log(inventory.items);
```

#### Properties

<a id="items"></a>

##### items

```ts
readonly items: readonly CraftingCargoItem[];
```

Defined in: [packages/sage/src/crafting/index.ts:82](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L82)

<a id="sequenceid"></a>

##### sequenceId

```ts
readonly sequenceId: number;
```

Defined in: [packages/sage/src/crafting/index.ts:80](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L80)

<a id="usedstorageunitsraw"></a>

##### usedStorageUnitsRaw

```ts
readonly usedStorageUnitsRaw: bigint;
```

Defined in: [packages/sage/src/crafting/index.ts:81](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L81)

***

<a id="craftingcargoitem"></a>

### CraftingCargoItem

Defined in: [packages/sage/src/crafting/index.ts:68](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L68)

A registry-resolved cargo amount used by a Recipe or Crafting Process.

#### Example

```ts
declare const item: CraftingCargoItem;
console.log(item.name, item.quantityRaw);
```

#### Extends

- [`CargoDefinitionSummary`](/reference/#cargodefinitionsummary)

#### Properties

<a id="categoryid"></a>

##### categoryId

```ts
readonly categoryId: number;
```

Defined in: [packages/sage/src/registry/index.ts:141](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/registry/index.ts#L141)

###### Inherited from

[`CargoDefinitionSummary`](/reference/#cargodefinitionsummary).[`categoryId`](/reference/#cargodefinitionsummary)

<a id="id"></a>

##### id

```ts
readonly id: number;
```

Defined in: [packages/sage/src/registry/index.ts:142](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/registry/index.ts#L142)

###### Inherited from

[`CargoDefinitionSummary`](/reference/#cargodefinitionsummary).[`id`](/reference/#cargodefinitionsummary)

<a id="mint"></a>

##### mint

```ts
readonly mint: Address;
```

Defined in: [packages/sage/src/registry/index.ts:143](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/registry/index.ts#L143)

###### Inherited from

[`CargoDefinitionSummary`](/reference/#cargodefinitionsummary).[`mint`](/reference/#cargodefinitionsummary)

<a id="name"></a>

##### name

```ts
readonly name: string;
```

Defined in: [packages/sage/src/registry/index.ts:144](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/registry/index.ts#L144)

###### Inherited from

[`CargoDefinitionSummary`](/reference/#cargodefinitionsummary).[`name`](/reference/#cargodefinitionsummary)

<a id="quantityraw"></a>

##### quantityRaw

```ts
readonly quantityRaw: bigint;
```

Defined in: [packages/sage/src/crafting/index.ts:69](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L69)

<a id="storagecost"></a>

##### storageCost

```ts
readonly storageCost: number;
```

Defined in: [packages/sage/src/registry/index.ts:149](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/registry/index.ts#L149)

Encoded storage cost with 8 fractional bits: 256 means one whole storage unit.
For a nonnegative bigint quantity, use `(quantity * BigInt(storageCost) + 255n) / 256n`.
Round each transfer row up before summing; Fleet capacities and pod usage are whole units.

###### Inherited from

[`CargoDefinitionSummary`](/reference/#cargodefinitionsummary).[`storageCost`](/reference/#cargodefinitionsummary)

***

<a id="craftingdefinitioncargoitem"></a>

### CraftingDefinitionCargoItem

Defined in: [packages/sage/src/crafting/index.ts:193](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L193)

One resolved cargo quantity used by a Hab building definition.

#### Example

```ts
declare const item: CraftingDefinitionCargoItem;
console.log(item.quantityRaw);
```

#### Extends

- [`CargoDefinitionSummary`](/reference/#cargodefinitionsummary)

#### Properties

<a id="categoryid-1"></a>

##### categoryId

```ts
readonly categoryId: number;
```

Defined in: [packages/sage/src/registry/index.ts:141](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/registry/index.ts#L141)

###### Inherited from

[`CargoDefinitionSummary`](/reference/#cargodefinitionsummary).[`categoryId`](/reference/#cargodefinitionsummary)

<a id="id-1"></a>

##### id

```ts
readonly id: number;
```

Defined in: [packages/sage/src/registry/index.ts:142](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/registry/index.ts#L142)

###### Inherited from

[`CargoDefinitionSummary`](/reference/#cargodefinitionsummary).[`id`](/reference/#cargodefinitionsummary)

<a id="mint-1"></a>

##### mint

```ts
readonly mint: Address;
```

Defined in: [packages/sage/src/registry/index.ts:143](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/registry/index.ts#L143)

###### Inherited from

[`CargoDefinitionSummary`](/reference/#cargodefinitionsummary).[`mint`](/reference/#cargodefinitionsummary)

<a id="name-1"></a>

##### name

```ts
readonly name: string;
```

Defined in: [packages/sage/src/registry/index.ts:144](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/registry/index.ts#L144)

###### Inherited from

[`CargoDefinitionSummary`](/reference/#cargodefinitionsummary).[`name`](/reference/#cargodefinitionsummary)

<a id="quantityraw-1"></a>

##### quantityRaw

```ts
readonly quantityRaw: bigint;
```

Defined in: [packages/sage/src/crafting/index.ts:194](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L194)

<a id="storagecost-1"></a>

##### storageCost

```ts
readonly storageCost: number;
```

Defined in: [packages/sage/src/registry/index.ts:149](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/registry/index.ts#L149)

Encoded storage cost with 8 fractional bits: 256 means one whole storage unit.
For a nonnegative bigint quantity, use `(quantity * BigInt(storageCost) + 255n) / 256n`.
Round each transfer row up before summing; Fleet capacities and pod usage are whole units.

###### Inherited from

[`CargoDefinitionSummary`](/reference/#cargodefinitionsummary).[`storageCost`](/reference/#cargodefinitionsummary)

***

<a id="craftinghabbuilding"></a>

### CraftingHabBuilding

Defined in: [packages/sage/src/crafting/index.ts:204](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L204)

A resolved Crafting Hab building definition and placed quantity.

#### Example

```ts
declare const building: CraftingHabBuilding;
console.log(building.definition.name, building.quantity);
```

#### Properties

<a id="definition"></a>

##### definition

```ts
readonly definition: {
  constructionCost: readonly CraftingDefinitionCargoItem[];
  constructionDurationSeconds: bigint;
  crewSlots: number;
  hubValue: number;
  id: number;
  jobCapacity: number;
  minimumTier: "one" | "two" | "three" | "four" | "five";
  modifiers: CraftingModifierData;
  name: string;
  neededCrew: number;
  netRates: readonly CargoDefinitionSummary & {
     unitsPerSecond: number;
     unitsPerSecondRaw: bigint;
  }[];
  providedTagIds: readonly number[];
  refunds: readonly CraftingDefinitionCargoItem[];
  requiredTagIds: readonly number[];
  researchRequirementIds: readonly number[];
  resourceCapacityRaw: bigint;
  slots: number;
  unlockedRecipes: readonly EntityRef<"recipe">[];
  xpValue: {
     raw: bigint;
     value: number;
  };
};
```

Defined in: [packages/sage/src/crafting/index.ts:206](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L206)

###### constructionCost

```ts
readonly constructionCost: readonly CraftingDefinitionCargoItem[];
```

###### constructionDurationSeconds

```ts
readonly constructionDurationSeconds: bigint;
```

###### crewSlots

```ts
readonly crewSlots: number;
```

###### hubValue

```ts
readonly hubValue: number;
```

###### id

```ts
readonly id: number;
```

###### jobCapacity

```ts
readonly jobCapacity: number;
```

###### minimumTier

```ts
readonly minimumTier: "one" | "two" | "three" | "four" | "five";
```

###### modifiers

```ts
readonly modifiers: CraftingModifierData;
```

###### name

```ts
readonly name: string;
```

###### neededCrew

```ts
readonly neededCrew: number;
```

###### netRates

```ts
readonly netRates: readonly CargoDefinitionSummary & {
  unitsPerSecond: number;
  unitsPerSecondRaw: bigint;
}[];
```

###### providedTagIds

```ts
readonly providedTagIds: readonly number[];
```

###### refunds

```ts
readonly refunds: readonly CraftingDefinitionCargoItem[];
```

###### requiredTagIds

```ts
readonly requiredTagIds: readonly number[];
```

###### researchRequirementIds

```ts
readonly researchRequirementIds: readonly number[];
```

###### resourceCapacityRaw

```ts
readonly resourceCapacityRaw: bigint;
```

###### slots

```ts
readonly slots: number;
```

###### unlockedRecipes

```ts
readonly unlockedRecipes: readonly EntityRef<"recipe">[];
```

###### xpValue

```ts
readonly xpValue: {
  raw: bigint;
  value: number;
};
```

###### xpValue.raw

```ts
readonly raw: bigint;
```

###### xpValue.value

```ts
readonly value: number;
```

<a id="quantity-1"></a>

##### quantity

```ts
readonly quantity: number;
```

Defined in: [packages/sage/src/crafting/index.ts:205](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L205)

***

<a id="craftinghabdefinitionsummary"></a>

### CraftingHabDefinitionSummary

Defined in: [packages/sage/src/crafting/index.ts:168](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L168)

A resolved Crafting Hab definition from the Game registry.

#### Example

```ts
declare const definition: CraftingHabDefinitionSummary;
console.log(definition.name, definition.placementCargo.name);
```

#### Properties

<a id="evictiongraceperiodseconds"></a>

##### evictionGracePeriodSeconds

```ts
readonly evictionGracePeriodSeconds: bigint;
```

Defined in: [packages/sage/src/crafting/index.ts:181](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L181)

<a id="hubvalue"></a>

##### hubValue

```ts
readonly hubValue: number;
```

Defined in: [packages/sage/src/crafting/index.ts:178](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L178)

<a id="id-2"></a>

##### id

```ts
readonly id: number;
```

Defined in: [packages/sage/src/crafting/index.ts:169](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L169)

<a id="name-2"></a>

##### name

```ts
readonly name: string;
```

Defined in: [packages/sage/src/crafting/index.ts:170](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L170)

<a id="placementcargo"></a>

##### placementCargo

```ts
readonly placementCargo: CargoDefinitionSummary;
```

Defined in: [packages/sage/src/crafting/index.ts:183](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L183)

<a id="placementfeemultiplier"></a>

##### placementFeeMultiplier

```ts
readonly placementFeeMultiplier: {
  raw: bigint;
  value: number;
};
```

Defined in: [packages/sage/src/crafting/index.ts:174](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L174)

###### raw

```ts
readonly raw: bigint;
```

###### value

```ts
readonly value: number;
```

<a id="providedtagids"></a>

##### providedTagIds

```ts
readonly providedTagIds: readonly number[];
```

Defined in: [packages/sage/src/crafting/index.ts:180](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L180)

<a id="rentmultiplier"></a>

##### rentMultiplier

```ts
readonly rentMultiplier: {
  raw: bigint;
  value: number;
};
```

Defined in: [packages/sage/src/crafting/index.ts:173](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L173)

###### raw

```ts
readonly raw: bigint;
```

###### value

```ts
readonly value: number;
```

<a id="requiredtagids"></a>

##### requiredTagIds

```ts
readonly requiredTagIds: readonly number[];
```

Defined in: [packages/sage/src/crafting/index.ts:179](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L179)

<a id="respawndurationseconds"></a>

##### respawnDurationSeconds

```ts
readonly respawnDurationSeconds: bigint;
```

Defined in: [packages/sage/src/crafting/index.ts:182](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L182)

<a id="slots"></a>

##### slots

```ts
readonly slots: number;
```

Defined in: [packages/sage/src/crafting/index.ts:172](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L172)

<a id="tier"></a>

##### tier

```ts
readonly tier: "one" | "two" | "three" | "four" | "five";
```

Defined in: [packages/sage/src/crafting/index.ts:171](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L171)

***

<a id="craftinghabsnapshot"></a>

### CraftingHabSnapshot

Defined in: [packages/sage/src/crafting/index.ts:239](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L239)

Immutable translated Crafting Hab infrastructure and production state.

#### Example

```ts
declare const hab: CraftingHabSnapshot;
console.log(hab.definition.name, hab.production.inventory.items);
```

#### Extends

- `Omit`\<`CraftingHabAccountData`, 
  \| `"buildings"`
  \| `"game"`
  \| `"ownerProfile"`
  \| `"production"`
  \| `"system"`
  \| `"unlockedRecipeIds"`\>

#### Extended by

- [`CraftingHabView`](/reference/#craftinghabview)

#### Properties

<a id="address"></a>

##### address

```ts
readonly address: Address;
```

Defined in: [packages/sage/src/crafting/index.ts:249](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L249)

<a id="availablejobslots"></a>

##### availableJobSlots

```ts
readonly availableJobSlots: number;
```

Defined in: [packages/sage/src/crafting/index.ts:255](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L255)

<a id="buildingdefinitionsequenceid"></a>

##### buildingDefinitionSequenceId

```ts
readonly buildingDefinitionSequenceId: number;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:171](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L171)

###### Inherited from

```ts
Omit.buildingDefinitionSequenceId
```

<a id="buildings"></a>

##### buildings

```ts
readonly buildings: readonly CraftingHabBuilding[];
```

Defined in: [packages/sage/src/crafting/index.ts:254](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L254)

<a id="constructionprogressatunixseconds"></a>

##### constructionProgressAtUnixSeconds

```ts
readonly constructionProgressAtUnixSeconds: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:175](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L175)

###### Inherited from

```ts
Omit.constructionProgressAtUnixSeconds
```

<a id="constructionremainingseconds"></a>

##### constructionRemainingSeconds

```ts
readonly constructionRemainingSeconds: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:174](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L174)

###### Inherited from

```ts
Omit.constructionRemainingSeconds
```

<a id="definition-1"></a>

##### definition

```ts
readonly definition: CraftingHabDefinitionSummary;
```

Defined in: [packages/sage/src/crafting/index.ts:253](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L253)

<a id="definitionid"></a>

##### definitionId

```ts
readonly definitionId: number;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:169](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L169)

###### Inherited from

```ts
Omit.definitionId
```

<a id="definitionsequenceid"></a>

##### definitionSequenceId

```ts
readonly definitionSequenceId: number;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:170](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L170)

###### Inherited from

```ts
Omit.definitionSequenceId
```

<a id="game"></a>

##### game

```ts
readonly game: EntityRef<"game">;
```

Defined in: [packages/sage/src/crafting/index.ts:250](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L250)

<a id="jobcapacity"></a>

##### jobCapacity

```ts
readonly jobCapacity: number;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:180](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L180)

###### Inherited from

```ts
Omit.jobCapacity
```

<a id="jobsrunning"></a>

##### jobsRunning

```ts
readonly jobsRunning: number;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:181](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L181)

###### Inherited from

```ts
Omit.jobsRunning
```

<a id="kind"></a>

##### kind

```ts
readonly kind: "craftingHabInstance";
```

Defined in: [packages/sage/src/crafting/index.ts:248](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L248)

<a id="lastrentatunixseconds"></a>

##### lastRentAtUnixSeconds

```ts
readonly lastRentAtUnixSeconds: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:173](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L173)

###### Inherited from

```ts
Omit.lastRentAtUnixSeconds
```

<a id="modifiers"></a>

##### modifiers

```ts
readonly modifiers: CraftingModifierData;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:182](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L182)

###### Inherited from

```ts
Omit.modifiers
```

<a id="neededcrew"></a>

##### neededCrew

```ts
readonly neededCrew: number;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:179](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L179)

Crew the Hab reserved, on a version-1 instance. A version-0 instance
stores an unverified nominal value instead.

###### Inherited from

```ts
Omit.neededCrew
```

<a id="ownerprofile"></a>

##### ownerProfile

```ts
readonly ownerProfile: EntityRef<"profile">;
```

Defined in: [packages/sage/src/crafting/index.ts:251](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L251)

<a id="production"></a>

##### production

```ts
readonly production: {
  inventory: CraftingCargoInventory;
  lastTickAtUnixSeconds: bigint;
  netRates: readonly CargoDefinitionSummary & {
     unitsPerSecond: number;
     unitsPerSecondRaw: bigint;
  }[];
  resourceCapacityRaw: bigint;
};
```

Defined in: [packages/sage/src/crafting/index.ts:257](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L257)

###### inventory

```ts
readonly inventory: CraftingCargoInventory;
```

###### lastTickAtUnixSeconds

```ts
readonly lastTickAtUnixSeconds: bigint;
```

###### netRates

```ts
readonly netRates: readonly CargoDefinitionSummary & {
  unitsPerSecond: number;
  unitsPerSecondRaw: bigint;
}[];
```

###### resourceCapacityRaw

```ts
readonly resourceCapacityRaw: bigint;
```

<a id="rentbalanceraw"></a>

##### rentBalanceRaw

```ts
readonly rentBalanceRaw: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:176](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L176)

###### Inherited from

```ts
Omit.rentBalanceRaw
```

<a id="state"></a>

##### state

```ts
readonly state: CraftingHabStateData;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:185](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L185)

###### Inherited from

```ts
Omit.state
```

<a id="system"></a>

##### system

```ts
readonly system: EntityRef<"starSystem">;
```

Defined in: [packages/sage/src/crafting/index.ts:252](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L252)

<a id="systemsequenceid"></a>

##### systemSequenceId

```ts
readonly systemSequenceId: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:172](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L172)

###### Inherited from

```ts
Omit.systemSequenceId
```

<a id="unlockedrecipes"></a>

##### unlockedRecipes

```ts
readonly unlockedRecipes: readonly EntityRef<"recipe">[];
```

Defined in: [packages/sage/src/crafting/index.ts:256](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L256)

<a id="version"></a>

##### version

```ts
readonly version: number;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:165](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L165)

###### Inherited from

```ts
Omit.version
```

#### Methods

<a id="tojson-1"></a>

##### toJSON()

```ts
toJSON(): unknown;
```

Defined in: [packages/sage/src/crafting/index.ts:266](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L266)

###### Returns

`unknown`

***

<a id="craftingprocesssnapshot"></a>

### CraftingProcessSnapshot

Defined in: [packages/sage/src/crafting/index.ts:276](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L276)

Immutable translated Crafting Process with resolved Recipe and inputs.

#### Example

```ts
declare const process: CraftingProcessSnapshot;
console.log(process.recipe.name, process.numCrew);
```

#### Extends

- `Omit`\<`CraftingProcessAccountData`, 
  \| `"craftingHab"`
  \| `"inputs"`
  \| `"profile"`
  \| `"recipe"`
  \| `"starbasePlayer"`
  \| `"system"`\>

#### Extended by

- [`CraftingProcessView`](/reference/#craftingprocessview)

#### Properties

<a id="address-1"></a>

##### address

```ts
readonly address: Address;
```

Defined in: [packages/sage/src/crafting/index.ts:281](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L281)

<a id="craftinghab"></a>

##### craftingHab?

```ts
readonly optional craftingHab?: EntityRef<"craftingHabInstance">;
```

Defined in: [packages/sage/src/crafting/index.ts:287](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L287)

The Process Hab, or absent when crafting without a Hab.

<a id="endsatunixseconds"></a>

##### endsAtUnixSeconds

```ts
readonly endsAtUnixSeconds: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:205](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L205)

###### Inherited from

```ts
Omit.endsAtUnixSeconds
```

<a id="feeescrowatlas"></a>

##### feeEscrowAtlas

```ts
readonly feeEscrowAtlas: number;
```

Defined in: [packages/sage/src/crafting/index.ts:289](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L289)

<a id="feeescrowraw"></a>

##### feeEscrowRaw

```ts
readonly feeEscrowRaw: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:206](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L206)

###### Inherited from

```ts
Omit.feeEscrowRaw
```

<a id="feegovernance"></a>

##### feeGovernance?

```ts
readonly optional feeGovernance?: Address;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:210](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L210)

Captured governance address, if present; never inferred from the current Recipe.

###### Inherited from

```ts
Omit.feeGovernance
```

<a id="feerecipient"></a>

##### feeRecipient?

```ts
readonly optional feeRecipient?: "atlas" | "dao-atlas";
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:208](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L208)

Captured original recipe destination; absent on legacy version 0 processes.

###### Inherited from

```ts
Omit.feeRecipient
```

<a id="feesnapshot"></a>

##### feeSnapshot?

```ts
readonly optional feeSnapshot?: {
  craftingFeeBasisPoints: number;
  localMarketFeeBasisPoints: number;
  localTreasuryShareBasisPoints: number;
};
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:212](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L212)

Captured routing rates; absent on legacy version 0 processes.

###### craftingFeeBasisPoints

```ts
readonly craftingFeeBasisPoints: number;
```

###### localMarketFeeBasisPoints

```ts
readonly localMarketFeeBasisPoints: number;
```

###### localTreasuryShareBasisPoints

```ts
readonly localTreasuryShareBasisPoints: number;
```

###### Inherited from

```ts
Omit.feeSnapshot
```

<a id="inputs"></a>

##### inputs

```ts
readonly inputs: CraftingCargoInventory;
```

Defined in: [packages/sage/src/crafting/index.ts:288](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L288)

<a id="kind-1"></a>

##### kind

```ts
readonly kind: "craftingProcess";
```

Defined in: [packages/sage/src/crafting/index.ts:280](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L280)

<a id="numcrew"></a>

##### numCrew

```ts
readonly numCrew: number;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:203](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L203)

###### Inherited from

```ts
Omit.numCrew
```

<a id="profile"></a>

##### profile

```ts
readonly profile: EntityRef<"profile">;
```

Defined in: [packages/sage/src/crafting/index.ts:283](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L283)

<a id="quantityraw-2"></a>

##### quantityRaw

```ts
readonly quantityRaw: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:202](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L202)

###### Inherited from

```ts
Omit.quantityRaw
```

<a id="recipe-1"></a>

##### recipe

```ts
readonly recipe: RecipeSnapshot;
```

Defined in: [packages/sage/src/crafting/index.ts:282](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L282)

<a id="starbaseplayer"></a>

##### starbasePlayer

```ts
readonly starbasePlayer: EntityRef<"starbasePlayer">;
```

Defined in: [packages/sage/src/crafting/index.ts:285](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L285)

<a id="starbasesequenceid"></a>

##### starbaseSequenceId

```ts
readonly starbaseSequenceId: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:200](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L200)

###### Inherited from

```ts
Omit.starbaseSequenceId
```

<a id="startsatunixseconds"></a>

##### startsAtUnixSeconds

```ts
readonly startsAtUnixSeconds: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:204](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L204)

###### Inherited from

```ts
Omit.startsAtUnixSeconds
```

<a id="system-1"></a>

##### system

```ts
readonly system: EntityRef<"starSystem">;
```

Defined in: [packages/sage/src/crafting/index.ts:284](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L284)

<a id="version-1"></a>

##### version

```ts
readonly version: number;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:195](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L195)

###### Inherited from

```ts
Omit.version
```

#### Methods

<a id="tojson-2"></a>

##### toJSON()

```ts
toJSON(): unknown;
```

Defined in: [packages/sage/src/crafting/index.ts:290](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L290)

###### Returns

`unknown`

***

<a id="recipesnapshot"></a>

### RecipeSnapshot

Defined in: [packages/sage/src/crafting/index.ts:99](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L99)

Immutable translated Recipe definition.

`usageCountRaw` and `usageLimitRaw` are the stored u64 counters: how many
Crafting Processes have been started from the Recipe and its maximum. A
start consumes one use whatever its quantity, and is possible only while the
count is below the limit, so a stored limit of `0n` is never usable. Every
Recipe observed on z.ink PTR stores `9007199254740991` (2^53 - 1) as its
limit; see `docs/evidence/crafting-zero-usage-limit.md`.

#### Example

```ts
declare const recipe: RecipeSnapshot;
console.log(recipe.ingredients, recipe.outputs);
```

#### Extends

- `Omit`\<`RecipeAccountData`, `"game"` \| `"id"` \| `"inputs"` \| `"outputs"`\>

#### Extended by

- [`RecipeView`](/reference/#recipeview)

#### Properties

<a id="address-2"></a>

##### address

```ts
readonly address: Address;
```

Defined in: [packages/sage/src/crafting/index.ts:104](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L104)

<a id="craftingdurationseconds"></a>

##### craftingDurationSeconds

```ts
readonly craftingDurationSeconds: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:103](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L103)

###### Inherited from

```ts
Omit.craftingDurationSeconds
```

<a id="fee"></a>

##### fee

```ts
readonly fee: {
  amountAtlas: number;
  amountRaw: bigint;
  recipient: "atlas" | "dao-atlas";
};
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:107](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L107)

###### amountAtlas

```ts
readonly amountAtlas: number;
```

###### amountRaw

```ts
readonly amountRaw: bigint;
```

###### recipient

```ts
readonly recipient: "atlas" | "dao-atlas";
```

###### Inherited from

```ts
Omit.fee
```

<a id="game-1"></a>

##### game

```ts
readonly game: EntityRef<"game">;
```

Defined in: [packages/sage/src/crafting/index.ts:105](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L105)

<a id="habrequired"></a>

##### habRequired

```ts
readonly habRequired: boolean;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:112](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L112)

###### Inherited from

```ts
Omit.habRequired
```

<a id="id-3"></a>

##### id

```ts
readonly id: number;
```

Defined in: [packages/sage/src/crafting/index.ts:106](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L106)

<a id="ingredients-1"></a>

##### ingredients

```ts
readonly ingredients: readonly CraftingCargoItem[];
```

Defined in: [packages/sage/src/crafting/index.ts:107](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L107)

<a id="kind-2"></a>

##### kind

```ts
readonly kind: "recipe";
```

Defined in: [packages/sage/src/crafting/index.ts:103](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L103)

<a id="minimumdurationseconds"></a>

##### minimumDurationSeconds

```ts
readonly minimumDurationSeconds: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:104](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L104)

###### Inherited from

```ts
Omit.minimumDurationSeconds
```

<a id="minimumstarbaselevel"></a>

##### minimumStarbaseLevel

```ts
readonly minimumStarbaseLevel: 
  | "level-0"
  | "level-1"
  | "level-2"
  | "level-3"
  | "level-4"
  | "level-5"
  | "css";
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:122](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L122)

Stored minimum Starbase level. Starting a crafting batch does not check
it; an Active status, research requirements, the usage limit and a
required Crafting Hab are what the game enforces.

###### Inherited from

```ts
Omit.minimumStarbaseLevel
```

<a id="modifierbounds"></a>

##### modifierBounds

```ts
readonly modifierBounds: {
  crewCount: CraftingModifierBoundsData;
  efficiency: CraftingModifierBoundsData;
  fee: CraftingModifierBoundsData;
  speed: CraftingModifierBoundsData;
};
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:130](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L130)

###### crewCount

```ts
readonly crewCount: CraftingModifierBoundsData;
```

###### efficiency

```ts
readonly efficiency: CraftingModifierBoundsData;
```

###### fee

```ts
readonly fee: CraftingModifierBoundsData;
```

###### speed

```ts
readonly speed: CraftingModifierBoundsData;
```

###### Inherited from

```ts
Omit.modifierBounds
```

<a id="name-3"></a>

##### name

```ts
readonly name: string;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:105](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L105)

###### Inherited from

```ts
Omit.name
```

<a id="outputs-1"></a>

##### outputs

```ts
readonly outputs: readonly CraftingCargoItem[];
```

Defined in: [packages/sage/src/crafting/index.ts:108](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L108)

<a id="researchrequirementids"></a>

##### researchRequirementIds

```ts
readonly researchRequirementIds: readonly number[];
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:136](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L136)

###### Inherited from

```ts
Omit.researchRequirementIds
```

<a id="status"></a>

##### status

```ts
readonly status: "active" | "deactivated";
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:106](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L106)

###### Inherited from

```ts
Omit.status
```

<a id="usagecountraw"></a>

##### usageCountRaw

```ts
readonly usageCountRaw: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:113](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L113)

###### Inherited from

```ts
Omit.usageCountRaw
```

<a id="usagelimitraw"></a>

##### usageLimitRaw

```ts
readonly usageLimitRaw: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:114](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L114)

###### Inherited from

```ts
Omit.usageLimitRaw
```

<a id="version-2"></a>

##### version

```ts
readonly version: number;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:100](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L100)

###### Inherited from

```ts
Omit.version
```

<a id="xpvalueraw"></a>

##### xpValueRaw

```ts
readonly xpValueRaw: bigint;
```

Defined in: [packages/sage/src/internal/c4/crafting.ts:118](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/internal/c4/crafting.ts#L118)

U32F32 fixed-point XP value (`raw / 2^32`). Completing a Process awards
`floor(value × quantity)` legacy XP, where quantity is the Process's locked
inputs divided by the Recipe's per-craft amounts, not its output count.

###### Inherited from

```ts
Omit.xpValueRaw
```

#### Methods

<a id="tojson-3"></a>

##### toJSON()

```ts
toJSON(): unknown;
```

Defined in: [packages/sage/src/crafting/index.ts:109](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L109)

###### Returns

`unknown`

## Type Aliases

<a id="craftingcrewassumption"></a>

### CraftingCrewAssumption

```ts
type CraftingCrewAssumption = 
  | {
  kind: "none";
}
  | {
  craftSpeed: number;
  crewCount: number;
  kind: "assumed";
};
```

Defined in: [packages/sage/src/crafting/estimate.ts:19](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L19)

Crew perks speed crafting up and lower the crew a batch needs, only when
the start transaction supplies the crew binding; account state cannot show
them. `none` matches a start without the binding. `assumed` applies a crew
speed factor from 0.75 to 1.25 to the research time modifier, kept within
the game's 0.5 to 1.0 band, and a crew-count factor from 0.87 to 1, both in
the game's 0.0001 steps. With the binding, a zero research time modifier is
raised to the 0.5 floor rather than left unchanged.

#### Example

```ts
const roster: CraftingCrewAssumption = { kind: 'assumed', craftSpeed: 0.9, crewCount: 0.95 };
```

***

<a id="craftingdiscoveryoptions"></a>

### CraftingDiscoveryOptions

```ts
type CraftingDiscoveryOptions = Omit<DiscoveryRequest, "filters" | "strategy">;
```

Defined in: [packages/sage/src/crafting/index.ts:56](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L56)

Options supported by targeted crafting discovery.

#### Example

```ts
const options: CraftingDiscoveryOptions = { commitment: 'confirmed' };
```

***

<a id="craftinghabdefinition"></a>

### CraftingHabDefinition

```ts
type CraftingHabDefinition = GameCraftingHabDefinitionData;
```

Defined in: [packages/sage/src/crafting/index.ts:126](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L126)

Immutable Crafting Hab container definition from the loaded Game catalog.

Unlike a placed Hab's `CraftingHabDefinitionSummary`, this independent
definition keeps its placement `cargoId` without resolving cargo. Multipliers
retain dimensionless exact raw bigint and ergonomic values. Global eviction
and respawn durations remain exact seconds. JSON serializes bigint as decimal
strings; the loaded catalog does not assert current chain freshness.

#### Example

```ts
declare const definition: CraftingHabDefinition;
console.log(definition.name, definition.cargoId, definition.rentMultiplier.raw);
```

***

<a id="craftingprocessstate"></a>

### CraftingProcessState

```ts
type CraftingProcessState = 
  | {
  kind: "scheduled";
}
  | {
  kind: "in-progress";
  remainingSeconds: bigint;
}
  | {
  kind: "complete";
};
```

Defined in: [packages/sage/src/crafting/index.ts:299](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L299)

Pure lifecycle projection for one Crafting Process at a given Unix time.

#### Example

```ts
const state: CraftingProcessState = { kind: 'scheduled' };
```

***

<a id="habbuildingdefinition"></a>

### HabBuildingDefinition

```ts
type HabBuildingDefinition = GameHabBuildingDefinitionData;
```

Defined in: [packages/sage/src/crafting/index.ts:1040](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L1040)

Immutable Hab building definition from the loaded Game catalog.
Keeps the existing Hab-specific modifiers, job capacity and unlocked recipes;
this is configuration, not the output of a placed building. Fixed-point values
retain exact raw bigint, and JSON serializes bigint as decimal strings.

#### Example

```ts
declare const definition: HabBuildingDefinition;
console.log(definition.modifiers.speed.value, definition.unlockedRecipeIds);
```

## Functions

<a id="derivecraftingbatchestimate"></a>

### deriveCraftingBatchEstimate()

```ts
function deriveCraftingBatchEstimate(input): CraftingBatchEstimate;
```

Defined in: [packages/sage/src/crafting/estimate.ts:134](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/estimate.ts#L134)

Estimates starting a proposed crafting batch, as the program computes it;
verified against the program's behaviour. Duration is the Recipe's duration
× quantity ÷ crew, rounded up and never below its minimum, and the fee is the
Recipe fee × quantity. A Crafting Hab then scales crew, duration and fee
(each rounded up) and quantity (rounded down) by its modifiers. The
Character's crafting efficiency scales quantity (rounded down) and its
crafting time scales duration (rounded up), so modifiers can take duration
below the Recipe's minimum. The fee then takes the Starbase's basis points,
rounded down. Ingredients are debited for the requested quantity; outputs are
credited for the process quantity. The Recipe's modifier bounds are not
applied when a batch starts.

Pure: no eligibility, ingredient balance, ATLAS balance, Recipe usage, Hab
job slot or Starbase level is checked, and nothing is reserved. Crew perks
are an explicit assumption; crafting yield perks are not active in the game.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `input` | [`CraftingBatchEstimateInput`](/reference/crafting/#craftingbatchestimateinput) |

#### Returns

[`CraftingBatchEstimate`](/reference/crafting/#craftingbatchestimate)

#### Example

```ts
declare const input: CraftingBatchEstimateInput;
const estimate = deriveCraftingBatchEstimate(input);
console.log(estimate.durationSeconds, estimate.processQuantity);
```

***

<a id="derivecraftingprocessstate"></a>

### deriveCraftingProcessState()

```ts
function deriveCraftingProcessState(process, atUnixSeconds): CraftingProcessState;
```

Defined in: [packages/sage/src/crafting/index.ts:1020](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L1020)

Derives the scheduled, active, or complete state at a Unix timestamp.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `process` | `Pick`\<[`CraftingProcessSnapshot`](/reference/crafting/#craftingprocesssnapshot), `"startsAtUnixSeconds"` \| `"endsAtUnixSeconds"`\> |
| `atUnixSeconds` | `bigint` |

#### Returns

[`CraftingProcessState`](/reference/crafting/#craftingprocessstate)

#### Example

```ts
declare const process: CraftingProcessSnapshot;
const state = deriveCraftingProcessState(process, 1_700_000_000n);
```

***

<a id="getcraftinghab"></a>

### getCraftingHab()

```ts
function getCraftingHab(
   context, 
   address, 
options?): Promise<CraftingHabSnapshot>;
```

Defined in: [packages/sage/src/crafting/index.ts:793](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L793)

Reads a required Crafting Hab by its signer-created account address.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `address` | [`Address`](/reference/#address-20) |
| `options?` | [`ReadOptions`](/reference/client/#readoptions) |

#### Returns

`Promise`\<[`CraftingHabSnapshot`](/reference/crafting/#craftinghabsnapshot)\>

#### Example

```ts
declare const ctx: SageContext;
declare const address: Address;
const hab = await getCraftingHab(ctx, address);
```

***

<a id="getcraftinghabdefinition"></a>

### getCraftingHabDefinition()

```ts
function getCraftingHabDefinition(context, id): Promise<GameCraftingHabDefinitionData>;
```

Defined in: [packages/sage/src/crafting/index.ts:137](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L137)

Loads one Crafting Hab container definition by its Game table id.
The catalog loads lazily without fetching a placed Hab or its placement cargo.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `id` | `number` |

#### Returns

`Promise`\<`GameCraftingHabDefinitionData`\>

#### Example

```ts
declare const ctx: SageContext;
const definition = await getCraftingHabDefinition(ctx, 7);
console.log(definition.slots, definition.respawnDurationSeconds);
```

***

<a id="getcraftinghabsbycharacter"></a>

### getCraftingHabsByCharacter()

```ts
function getCraftingHabsByCharacter(
   context, 
   character, 
options?): Promise<readonly CraftingHabSnapshot[]>;
```

Defined in: [packages/sage/src/crafting/index.ts:981](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L981)

Discovers Crafting Habs for the Profile stored by one Character.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `character` | [`Address`](/reference/#address-20) |
| `options?` | [`CraftingDiscoveryOptions`](/reference/crafting/#craftingdiscoveryoptions) |

#### Returns

`Promise`\<readonly [`CraftingHabSnapshot`](/reference/crafting/#craftinghabsnapshot)[]\>

#### Example

```ts
declare const ctx: SageContext;
declare const character: Address;
const habs = await getCraftingHabsByCharacter(ctx, character);
```

***

<a id="getcraftinghabsbyprofile"></a>

### getCraftingHabsByProfile()

```ts
function getCraftingHabsByProfile(
   context, 
   profile, 
options?): Promise<readonly CraftingHabSnapshot[]>;
```

Defined in: [packages/sage/src/crafting/index.ts:880](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L880)

Discovers Crafting Habs owned by one Player Profile.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `profile` | [`Address`](/reference/#address-20) |
| `options?` | [`CraftingDiscoveryOptions`](/reference/crafting/#craftingdiscoveryoptions) |

#### Returns

`Promise`\<readonly [`CraftingHabSnapshot`](/reference/crafting/#craftinghabsnapshot)[]\>

#### Example

```ts
declare const ctx: SageContext;
declare const profile: Address;
const habs = await getCraftingHabsByProfile(ctx, profile);
```

***

<a id="getcraftinghabsbystarbaseplayer"></a>

### getCraftingHabsByStarbasePlayer()

```ts
function getCraftingHabsByStarbasePlayer(
   context, 
   player, 
options?): Promise<readonly CraftingHabSnapshot[]>;
```

Defined in: [packages/sage/src/crafting/index.ts:930](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L930)

Discovers Crafting Habs for the Profile and System stored by a StarbasePlayer.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `player` | [`Address`](/reference/#address-20) |
| `options?` | [`CraftingDiscoveryOptions`](/reference/crafting/#craftingdiscoveryoptions) |

#### Returns

`Promise`\<readonly [`CraftingHabSnapshot`](/reference/crafting/#craftinghabsnapshot)[]\>

#### Example

```ts
declare const ctx: SageContext;
declare const player: Address;
const habs = await getCraftingHabsByStarbasePlayer(ctx, player);
```

***

<a id="getcraftingprocess"></a>

### getCraftingProcess()

```ts
function getCraftingProcess(
   context, 
   address, 
options?): Promise<CraftingProcessSnapshot>;
```

Defined in: [packages/sage/src/crafting/index.ts:835](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L835)

Reads a required Crafting Process by its signer-created account address.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `address` | [`Address`](/reference/#address-20) |
| `options?` | [`ReadOptions`](/reference/client/#readoptions) |

#### Returns

`Promise`\<[`CraftingProcessSnapshot`](/reference/crafting/#craftingprocesssnapshot)\>

#### Example

```ts
declare const ctx: SageContext;
declare const address: Address;
const process = await getCraftingProcess(ctx, address);
```

***

<a id="getcraftingprocessesbycharacter"></a>

### getCraftingProcessesByCharacter()

```ts
function getCraftingProcessesByCharacter(
   context, 
   character, 
options?): Promise<readonly CraftingProcessSnapshot[]>;
```

Defined in: [packages/sage/src/crafting/index.ts:1001](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L1001)

Discovers Crafting Processes for the Profile stored by one Character.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `character` | [`Address`](/reference/#address-20) |
| `options?` | [`CraftingDiscoveryOptions`](/reference/crafting/#craftingdiscoveryoptions) |

#### Returns

`Promise`\<readonly [`CraftingProcessSnapshot`](/reference/crafting/#craftingprocesssnapshot)[]\>

#### Example

```ts
declare const ctx: SageContext;
declare const character: Address;
const processes = await getCraftingProcessesByCharacter(ctx, character);
```

***

<a id="getcraftingprocessesbyprofile"></a>

### getCraftingProcessesByProfile()

```ts
function getCraftingProcessesByProfile(
   context, 
   profile, 
options?): Promise<readonly CraftingProcessSnapshot[]>;
```

Defined in: [packages/sage/src/crafting/index.ts:906](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L906)

Discovers Crafting Processes belonging to one Player Profile.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `profile` | [`Address`](/reference/#address-20) |
| `options?` | [`CraftingDiscoveryOptions`](/reference/crafting/#craftingdiscoveryoptions) |

#### Returns

`Promise`\<readonly [`CraftingProcessSnapshot`](/reference/crafting/#craftingprocesssnapshot)[]\>

#### Example

```ts
declare const ctx: SageContext;
declare const profile: Address;
const processes = await getCraftingProcessesByProfile(ctx, profile);
```

***

<a id="getcraftingprocessesbystarbaseplayer"></a>

### getCraftingProcessesByStarbasePlayer()

```ts
function getCraftingProcessesByStarbasePlayer(
   context, 
   player, 
options?): Promise<readonly CraftingProcessSnapshot[]>;
```

Defined in: [packages/sage/src/crafting/index.ts:957](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L957)

Discovers Crafting Processes linked to one StarbasePlayer.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `player` | [`Address`](/reference/#address-20) |
| `options?` | [`CraftingDiscoveryOptions`](/reference/crafting/#craftingdiscoveryoptions) |

#### Returns

`Promise`\<readonly [`CraftingProcessSnapshot`](/reference/crafting/#craftingprocesssnapshot)[]\>

#### Example

```ts
declare const ctx: SageContext;
declare const player: Address;
const processes = await getCraftingProcessesByStarbasePlayer(ctx, player);
```

***

<a id="gethabbuildingdefinition"></a>

### getHabBuildingDefinition()

```ts
function getHabBuildingDefinition(context, id): Promise<GameHabBuildingDefinitionData>;
```

Defined in: [packages/sage/src/crafting/index.ts:1051](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L1051)

Loads one Hab building definition without fetching a placed Crafting Hab.
The returned definition reflects the loaded section, not proven-current chain state.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `id` | `number` |

#### Returns

`Promise`\<`GameHabBuildingDefinitionData`\>

#### Example

```ts
declare const ctx: SageContext;
const building = await getHabBuildingDefinition(ctx, 7);
console.log(building.jobCapacity, building.constructionDurationSeconds);
```

***

<a id="getrecipe"></a>

### getRecipe()

```ts
function getRecipe(
   context, 
   address, 
options?): Promise<RecipeSnapshot>;
```

Defined in: [packages/sage/src/crafting/index.ts:729](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L729)

Reads a required Recipe by its derived account address.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `address` | [`Address`](/reference/#address-20) |
| `options?` | [`ReadOptions`](/reference/client/#readoptions) |

#### Returns

`Promise`\<[`RecipeSnapshot`](/reference/crafting/#recipesnapshot)\>

#### Example

```ts
declare const ctx: SageContext;
declare const address: Address;
const recipe = await getRecipe(ctx, address);
```

***

<a id="getrecipebyid"></a>

### getRecipeById()

```ts
function getRecipeById(
   context, 
   recipeId, 
options?): Promise<RecipeSnapshot>;
```

Defined in: [packages/sage/src/crafting/index.ts:772](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L772)

Derives and reads one Recipe from the configured Game and recipe id.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `recipeId` | `number` |
| `options?` | [`ReadOptions`](/reference/client/#readoptions) |

#### Returns

`Promise`\<[`RecipeSnapshot`](/reference/crafting/#recipesnapshot)\>

#### Example

```ts
declare const ctx: SageContext;
const recipe = await getRecipeById(ctx, 7);
```

***

<a id="listcraftinghabdefinitions"></a>

### listCraftingHabDefinitions()

```ts
function listCraftingHabDefinitions(context): Promise<readonly GameCraftingHabDefinitionData[]>;
```

Defined in: [packages/sage/src/crafting/index.ts:155](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L155)

Lists the loaded Crafting Hab containers as immutable canonical definitions.
The array is retained per section generation and shares by-id lookup objects.
Refresh replaces both together; previously returned arrays remain immutable
snapshots. This catalog carries no proof of latest chain state or sort order.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |

#### Returns

`Promise`\<readonly `GameCraftingHabDefinitionData`[]\>

#### Example

```ts
declare const ctx: SageContext;
const definitions = await listCraftingHabDefinitions(ctx);
console.log(definitions.map(definition => definition.name));
```

***

<a id="listhabbuildingdefinitions"></a>

### listHabBuildingDefinitions()

```ts
function listHabBuildingDefinitions(context): Promise<readonly GameHabBuildingDefinitionData[]>;
```

Defined in: [packages/sage/src/crafting/index.ts:1069](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L1069)

Lists the loaded Hab building catalog as immutable canonical definitions.
Shares objects with by-id lookups and retains the array for its section
generation. Refresh replaces both together; older returned arrays remain
immutable snapshots. No sort order or latest-chain freshness is promised.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |

#### Returns

`Promise`\<readonly `GameHabBuildingDefinitionData`[]\>

#### Example

```ts
declare const ctx: SageContext;
const buildings = await listHabBuildingDefinitions(ctx);
console.log(buildings.map(building => building.name));
```

***

<a id="listrecipes"></a>

### listRecipes()

```ts
function listRecipes(context, options?): Promise<readonly RecipeSnapshot[]>;
```

Defined in: [packages/sage/src/crafting/index.ts:698](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L698)

Discovers every Recipe reported for the configured Game, active or deactivated.
Returns frozen snapshots sorted by numeric id; reported failures reject the
entire catalog. Each completed call reconsults discovery (a configured indexer
takes precedence), but cargo definitions may be reused by the context registry.
`no-store` prevents discovered Recipe cache writes, not registry retention.
Recipe commitment applies to discovery and direct candidate validation; cargo
resolution uses the context commitment. Read metadata is provenance, not an
atomic-slot or provider-completeness guarantee.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `options?` | [`CraftingDiscoveryOptions`](/reference/crafting/#craftingdiscoveryoptions) |

#### Returns

`Promise`\<readonly [`RecipeSnapshot`](/reference/crafting/#recipesnapshot)[]\>

#### Example

```ts
declare const ctx: SageContext;
const recipes = await listRecipes(ctx, { policy: 'no-store' });
console.log(recipes.map(recipe => recipe.name));
```

***

<a id="maybegetcraftinghab"></a>

### maybeGetCraftingHab()

```ts
function maybeGetCraftingHab(
   context, 
   address, 
   options?): Promise<
  | CraftingHabSnapshot
| undefined>;
```

Defined in: [packages/sage/src/crafting/index.ts:813](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L813)

Reads an optional Crafting Hab by address.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `address` | [`Address`](/reference/#address-20) |
| `options?` | [`ReadOptions`](/reference/client/#readoptions) |

#### Returns

`Promise`\<
  \| [`CraftingHabSnapshot`](/reference/crafting/#craftinghabsnapshot)
  \| `undefined`\>

#### Example

```ts
declare const ctx: SageContext;
declare const address: Address;
const hab = await maybeGetCraftingHab(ctx, address);
```

***

<a id="maybegetcraftingprocess"></a>

### maybeGetCraftingProcess()

```ts
function maybeGetCraftingProcess(
   context, 
   address, 
   options?): Promise<
  | CraftingProcessSnapshot
| undefined>;
```

Defined in: [packages/sage/src/crafting/index.ts:856](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L856)

Reads an optional Crafting Process by address.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `address` | [`Address`](/reference/#address-20) |
| `options?` | [`ReadOptions`](/reference/client/#readoptions) |

#### Returns

`Promise`\<
  \| [`CraftingProcessSnapshot`](/reference/crafting/#craftingprocesssnapshot)
  \| `undefined`\>

#### Example

```ts
declare const ctx: SageContext;
declare const address: Address;
const process = await maybeGetCraftingProcess(ctx, address);
```

***

<a id="maybegetrecipe"></a>

### maybeGetRecipe()

```ts
function maybeGetRecipe(
   context, 
   address, 
options?): Promise<RecipeSnapshot | undefined>;
```

Defined in: [packages/sage/src/crafting/index.ts:749](https://github.com/Aephia/atlas-kit/blob/v0.7.0/packages/sage/src/crafting/index.ts#L749)

Reads an optional Recipe by address.

#### Parameters

| Parameter | Type |
| ------ | ------ |
| `context` | [`SageContext`](/reference/#sagecontext) |
| `address` | [`Address`](/reference/#address-20) |
| `options?` | [`ReadOptions`](/reference/client/#readoptions) |

#### Returns

`Promise`\<[`RecipeSnapshot`](/reference/crafting/#recipesnapshot) \| `undefined`\>

#### Example

```ts
declare const ctx: SageContext;
declare const address: Address;
const recipe = await maybeGetRecipe(ctx, address);
```
