SpaceNinjaServer/src/types/purchaseTypes.ts
OrdisPrime d091af4778
Basic purchasing + custom purchasing API (#20)
Endpoint for custom API: https://localhost:443/custom/addItem
example request:
{
"type": "Weapon",
"internalName": "/Lotus/Weapons/Grineer/Pistols/GrineerMicrowavegun/GrnMicrowavePistol",
"accountId": "6488fd2e7bec200069ca4242"
}
2023-06-14 02:26:19 +02:00

44 lines
1023 B
TypeScript

/* eslint-disable prettier/prettier */
import { ISuitDatabase } from "@/src/types/inventoryTypes/SuitTypes";
import { IWeaponResponse } from "@/src/types/inventoryTypes/weaponTypes";
export interface IPurchaseRequest {
PurchaseParams: IPurchaseParams;
buildLabel: string;
}
export interface IPurchaseParams {
Source: number;
StoreItem: string;
StorePage: string;
SearchTerm: string;
CurrentLocation: string;
Quantity: number;
UsePremium: boolean;
ExpectedPrice: number;
}
export interface IPurchaseResponse {
InventoryChanges: {
SuitBin?: IBinChanges;
WeaponBin?: IBinChanges;
Suits?: ISuitDatabase[];
LongGuns?: IWeaponResponse[];
Pistols?: IWeaponResponse[];
Melee?: IWeaponResponse[];
PremiumCredits?: number;
RegularCredits?: number;
};
}
export type IBinChanges = {
count: number;
platinum: number;
Slots: number;
};
export enum SlotType {
SUIT = "SuitBin",
WEAPON = "WeaponBin"
}