openapi: 3.1.0 info: title: OpenAPI definition version: v0 servers: - url: http://localhost:8080 description: Generated server url paths: /rule-books/{ruleBookId}: get: tags: - rule-book summary: Find a rule book by its id operationId: findRuleBookById parameters: - name: ruleBookId in: path description: Id of the rule book required: true schema: type: string format: uuid responses: "200": description: The rule book content: '*/*': schema: $ref: "#/components/schemas/RuleBookResponse" "404": description: No rule book with this id put: tags: - rule-book summary: Update a rule book operationId: updateRuleBook parameters: - name: ruleBookId in: path description: Id of the rule book required: true schema: type: string format: uuid requestBody: description: New state of the rule book content: application/json: schema: $ref: "#/components/schemas/UpdateRuleBookRequest" required: true responses: "200": description: The updated rule book content: '*/*': schema: $ref: "#/components/schemas/RuleBookResponse" "400": description: Invalid request (e.g. blank name) /ledgers/main/{ledgerId}: put: tags: - ledger summary: Update a main ledger operationId: updateMainLedger parameters: - name: ledgerId in: path description: Id of the main ledger required: true schema: type: string format: uuid requestBody: description: New state of the main ledger content: application/json: schema: $ref: "#/components/schemas/UpdateMainLedgerRequest" required: true responses: "200": description: The updated main ledger content: '*/*': schema: $ref: "#/components/schemas/MainLedgerResponse" "400": description: "The ledger is not a main ledger, or the request is invalid" "404": description: No ledger with this id /ledgers/combined/{ledgerId}: put: tags: - ledger summary: Update a combined ledger operationId: updateCombinedLedger parameters: - name: ledgerId in: path description: Id of the combined ledger required: true schema: type: string format: uuid requestBody: description: New state of the combined ledger content: application/json: schema: $ref: "#/components/schemas/UpdateCombinedLedgerRequest" required: true responses: "200": description: The updated combined ledger content: '*/*': schema: $ref: "#/components/schemas/CombinedLedgerResponse" "400": description: "The ledger is not a combined ledger, or the request is invalid" "404": description: No ledger with this id /characters/{characterId}/rule-book: get: tags: - character-rule-book summary: Find the rule book assigned to a character operationId: findCharacterRuleBookByCharacterId parameters: - name: characterId in: path description: Id of the character required: true schema: type: integer format: int64 responses: "200": description: The rule book assignment of the character content: '*/*': schema: $ref: "#/components/schemas/CharacterRuleBookResponse" "400": description: Invalid character id "404": description: No rule book assigned to this character put: tags: - character-rule-book summary: Assign a rule book to a character operationId: setCharacterRuleBookForCharacter parameters: - name: characterId in: path description: Id of the character required: true schema: type: integer format: int64 requestBody: description: Rule book and ledger bindings to assign content: application/json: schema: $ref: "#/components/schemas/SetCharacterRuleBookRequest" required: true responses: "200": description: The rule book assignment of the character content: '*/*': schema: $ref: "#/components/schemas/CharacterRuleBookResponse" "400": description: "The referenced rule book or a bound ledger does not exist,\ \ or a ledger binding is missing" /rule-books: get: tags: - rule-book summary: Find all rule books operationId: findAllRuleBooks responses: "200": description: All rule books content: '*/*': schema: type: array items: $ref: "#/components/schemas/RuleBookResponse" post: tags: - rule-book summary: Create a rule book operationId: createRuleBook requestBody: description: Rule book to create content: application/json: schema: $ref: "#/components/schemas/CreateRuleBookRequest" required: true responses: "201": description: The created rule book content: '*/*': schema: $ref: "#/components/schemas/RuleBookResponse" "400": description: Invalid request (e.g. blank name) /process-activities: post: tags: - processing summary: Process new activities for all characters with a usable token operationId: processNewActivities responses: "200": description: New activities processed /ledgers/main: post: tags: - ledger summary: Create a main ledger operationId: createMainLedger requestBody: description: Main ledger to create content: application/json: schema: $ref: "#/components/schemas/CreateMainLedgerRequest" required: true responses: "201": description: The created main ledger content: '*/*': schema: $ref: "#/components/schemas/MainLedgerResponse" "400": description: Invalid request (e.g. blank name) /ledgers/combined: post: tags: - ledger summary: Create a combined ledger operationId: createCombinedLedger requestBody: description: Combined ledger to create content: application/json: schema: $ref: "#/components/schemas/CreateCombinedLedgerRequest" required: true responses: "201": description: The created combined ledger content: '*/*': schema: $ref: "#/components/schemas/CombinedLedgerResponse" "400": description: "Invalid request (e.g. blank name, a member ledger missing\ \ or already contained)" /activity/fetch/{characterId}: post: tags: - activity summary: Fetch new activities for a character from the EVE API operationId: fetchNewActivitiesForCharacter parameters: - name: characterId in: path description: Id of the character required: true schema: type: integer format: int64 responses: "200": description: New activities fetched and stored "400": description: No character with this id /ledgers: get: tags: - ledger summary: Find all ledgers operationId: findAllLedgers responses: "200": description: All ledgers content: '*/*': schema: type: array items: oneOf: - $ref: "#/components/schemas/CombinedLedgerResponse" - $ref: "#/components/schemas/MainLedgerResponse" /ledgers/{ledgerId}: get: tags: - ledger summary: Find a ledger by its id operationId: findLedgerById parameters: - name: ledgerId in: path description: Id of the ledger required: true schema: type: string format: uuid responses: "200": description: The ledger content: '*/*': schema: oneOf: - $ref: "#/components/schemas/CombinedLedgerResponse" - $ref: "#/components/schemas/MainLedgerResponse" "400": description: The ledger cannot be exposed (system ledger) "404": description: No ledger with this id /ledgers/{ledgerId}/transactions: get: tags: - transaction summary: Find all transactions in a ledger operationId: finAllTransactionsInLedger parameters: - name: ledgerId in: path description: Id of the ledger required: true schema: type: string format: uuid responses: "200": description: All transactions in the ledger content: '*/*': schema: type: array items: $ref: "#/components/schemas/TransactionResponse" "404": description: No ledger with this id /ledgers/{ledgerId}/balance: get: tags: - ledger summary: Find the balance of a ledger operationId: findBalanceByLedgerId parameters: - name: ledgerId in: path description: Id of the ledger required: true schema: type: string format: uuid responses: "200": description: The balance of the ledger content: '*/*': schema: $ref: "#/components/schemas/BalanceResponse" "404": description: No ledger with this id /characters: get: tags: - character summary: Find all characters with a usable token operationId: findAllCharacters responses: "200": description: All characters with a usable token content: '*/*': schema: type: array items: $ref: "#/components/schemas/CharacterResponse" components: schemas: RuleClauseResponse: type: object properties: rate: type: string enum: - NONE - VALUE - JITA_BUY - JITA_SELL - EVE_ESTIMATE fromLedgerRef: type: string pattern: "[a-z]+(-[a-z]+)*" toLedgerRef: type: string pattern: "[a-z]+(-[a-z]+)*" required: - fromLedgerRef - rate - toLedgerRef RuleResponse: type: object properties: clauses: type: array items: $ref: "#/components/schemas/RuleClauseResponse" required: - clauses UpdateRuleBookRequest: type: object properties: name: type: string ledgerRefs: type: array items: type: string pattern: "[a-z]+(-[a-z]+)*" rules: type: object additionalProperties: $ref: "#/components/schemas/RuleResponse" required: - ledgerRefs - name - rules RuleBookResponse: type: object properties: ruleBookId: type: string format: uuid name: type: string ledgerRefs: type: array items: type: string pattern: "[a-z]+(-[a-z]+)*" rules: type: object additionalProperties: $ref: "#/components/schemas/RuleResponse" required: - ledgerRefs - name - ruleBookId - rules UpdateMainLedgerRequest: type: object properties: name: type: string required: - name MainLedgerResponse: allOf: - $ref: "#/components/schemas/LedgerResponse" - type: object properties: ledgerId: type: string format: uuid name: type: string balance: type: number type: type: string enum: - MAIN required: - balance - ledgerId - name UpdateCombinedLedgerRequest: type: object properties: name: type: string memberLedgerIds: type: array items: type: string format: uuid required: - memberLedgerIds - name CombinedLedgerResponse: allOf: - $ref: "#/components/schemas/LedgerResponse" - type: object properties: ledgerId: type: string format: uuid name: type: string balance: type: number memberLedgerIds: type: array items: type: string format: uuid type: type: string enum: - COMBINED required: - balance - ledgerId - memberLedgerIds - name SetCharacterRuleBookRequest: type: object properties: ruleBookId: type: string format: uuid bindings: type: object additionalProperties: type: string format: uuid required: - bindings - ruleBookId CharacterRuleBookResponse: type: object properties: characterId: type: integer format: int64 ruleBookId: type: string format: uuid bindings: type: object additionalProperties: type: string format: uuid required: - bindings - characterId - ruleBookId CreateRuleBookRequest: type: object properties: name: type: string ledgerRefs: type: array items: type: string pattern: "[a-z]+(-[a-z]+)*" rules: type: object additionalProperties: $ref: "#/components/schemas/RuleResponse" required: - ledgerRefs - name - rules CreateMainLedgerRequest: type: object properties: name: type: string required: - name CreateCombinedLedgerRequest: type: object properties: name: type: string memberLedgerIds: type: array items: type: string format: uuid required: - memberLedgerIds - name LedgerResponse: type: object discriminator: propertyName: type properties: type: type: string enum: - MAIN - COMBINED IskTransferResponse: allOf: - $ref: "#/components/schemas/TransferResponse" - type: object properties: fromLedgerId: type: string format: uuid toLedgerId: type: string format: uuid amount: type: number type: type: string enum: - ISK required: - amount - fromLedgerId - toLedgerId ItemTransferResponse: allOf: - $ref: "#/components/schemas/TransferResponse" - type: object properties: fromLedgerId: type: string format: uuid toLedgerId: type: string format: uuid marketTypeId: type: integer format: int64 quantity: type: integer format: int64 type: type: string enum: - ITEM required: - fromLedgerId - marketTypeId - quantity - toLedgerId TransactionResponse: type: object properties: transactionId: type: string format: uuid characterId: type: integer format: int64 datetime: type: string format: date-time description: type: string transfers: type: array items: oneOf: - $ref: "#/components/schemas/IskTransferResponse" - $ref: "#/components/schemas/ItemTransferResponse" required: - characterId - datetime - description - transactionId - transfers TransferResponse: type: object discriminator: propertyName: type properties: type: type: string enum: - ISK - ITEM BalanceResponse: type: object properties: iskBalance: type: number itemBalances: type: array items: $ref: "#/components/schemas/ItemBalanceResponse" required: - iskBalance - itemBalances ItemBalanceResponse: type: object properties: typeId: type: integer format: int64 quantity: type: integer format: int64 required: - quantity - typeId CharacterResponse: type: object properties: characterId: type: integer format: int64 name: type: string required: - characterId - name