Class SymbolApiController

java.lang.Object
com.bluebell.greenhouse.planter.controllers.symbol.SymbolApiController

@RestController @RequestMapping("${bluebell.base.api.controller.endpoint}/symbol") @CrossOrigin(origins="*", methods={GET,DELETE,POST,PUT}) public class SymbolApiController extends Object
API controller for symbols & equities.
Version:
3.0.6
Author:
Stephen Prizio
  • Constructor Details

    • SymbolApiController

      public SymbolApiController()
  • Method Details

    • getTradedSymbols

      @GetMapping("/get-traded-symbols") public org.springframework.http.ResponseEntity<Set<String>> getTradedSymbols(@ResolvedAccount AccountRequestContext context)
      Returns a ResponseEntity containing the symbols that were traded on this account.
      Parameters:
      context - AccountRequestContext
      Returns:
      ResponseEntity
    • getSymbolsPaged

      @GetMapping("/search-symbols") public org.springframework.http.ResponseEntity<PaginatedSymbolDTO> getSymbolsPaged(@ModelAttribute SymbolSearchRequest searchRequest)
      Return a ResponseEntity containing Symbols filtered.
      Parameters:
      searchRequest - SymbolSearchRequest
      Returns:
      ResponseEntity
    • getSymbolDetails

      @GetMapping("/get-symbol-details") public org.springframework.http.ResponseEntity<SymbolDTO> getSymbolDetails(@RequestParam("symbolId") String query)
      Returns a ResponseEntity containing a SymbolDTO.
      Parameters:
      query - search query
      Returns:
      ResponseEntity
    • getAvailableSymbolsForAssignment

      @GetMapping("/get-assignable-symbols") public org.springframework.http.ResponseEntity<List<SymbolDTO>> getAvailableSymbolsForAssignment()
      Returns a list of SymbolDTOs ready for assignment.
      Returns:
      ResponseEntity
    • getNewsLookupSymbols

      @GetMapping("/get-news-lookup-symbols") public org.springframework.http.ResponseEntity<List<NewsLookupSymbolDTO>> getNewsLookupSymbols()
      Returns a list of NewsLookupSymbolDTOs eligible for news lookup.
      Returns:
      ResponseEntity
    • getSymbolSentiment

      @GetMapping("/get-symbol-sentiment") public org.springframework.http.ResponseEntity<List<SymbolSentimentPointDTO>> getSymbolSentiment(@ModelAttribute SymbolSentimentRequest sentimentRequest)
      Returns symbol sentiment points for a ticker.
      Parameters:
      sentimentRequest - SymbolSentimentRequest
      Returns:
      ResponseEntity
    • getSymbolSentimentSummary

      @GetMapping("/get-symbol-sentiment-summary") public org.springframework.http.ResponseEntity<SymbolSentimentPointDTO> getSymbolSentimentSummary(@ModelAttribute SymbolSentimentRequest sentimentRequest)
      Returns aggregated symbol sentiment for a ticker.
      Parameters:
      sentimentRequest - SymbolSentimentRequest
      Returns:
      ResponseEntity
    • exportSymbolRegistry

      @GetMapping(value="/export-symbol-registry", produces="application/json") public org.springframework.http.ResponseEntity<org.springframework.core.io.ByteArrayResource> exportSymbolRegistry()
      Exports the raw symbol registry JSON file.
      Returns:
      ResponseEntity with ByteArrayResource for download
    • postCreateNewSymbol

      @PostMapping("/create-symbol") public org.springframework.http.ResponseEntity<SymbolDTO> postCreateNewSymbol(@Valid @RequestBody @Valid CreateUpdateSymbolDTO data)
      Creates a new Symbol.
      Parameters:
      data - CreateUpdateSymbolDTO
      Returns:
      ResponseEntity
    • postReassignSymbol

      @PostMapping("/re-assign-symbol") public org.springframework.http.ResponseEntity<Boolean> postReassignSymbol(@RequestParam("oldSymbolId") String oldTicker, @RequestParam("newSymbolId") String newTicker, @RequestParam("dataSource") String dataSource)
      Reassigns a Symbol as a SymbolAlias to a new Symbol.
      Parameters:
      oldTicker - old symbol
      newTicker - new symbol
      dataSource - DataSource string
      Returns:
      ResponseEntity
    • postAssignToSymbol

      @PostMapping("/assign-to-symbol") public org.springframework.http.ResponseEntity<Boolean> postAssignToSymbol(@RequestParam("symbolAliasUid") String symbolAliasUid, @RequestParam("symbolId") String symbolId)
      Assigns the given SymbolAlias to a new Symbol.
      Parameters:
      symbolAliasUid - symbol alias uid
      symbolId - symbol id
      Returns:
      ResponseEntity
    • postEnrichSymbol

      @PostMapping("/enrich-symbol") public org.springframework.http.ResponseEntity<ManualSymbolEnrichmentResponse> postEnrichSymbol(@RequestParam("ticker") String ticker, @RequestParam("exchangeMic") String exchangeMic, @RequestParam("symbolType") String symbolType)
      Enriches a symbol's metadata with additional information from the web.
      Parameters:
      ticker - symbol ticker
      exchangeMic - symbol exchange MIC
      symbolType - symbol type
      Returns:
      ResponseEntity
    • putUpdateSymbol

      @PutMapping("/update-symbol") public org.springframework.http.ResponseEntity<SymbolDTO> putUpdateSymbol(@Valid @RequestBody @Valid CreateUpdateSymbolDTO data, @RequestParam("symbolId") String symbolId)
      Updates an existing Symbol.
      Parameters:
      data - CreateUpdateSymbolDTO
      symbolId - symbol id
      Returns:
      ResponseEntity
    • deleteSymbol

      @DeleteMapping("/delete-symbol") public org.springframework.http.ResponseEntity<Void> deleteSymbol(@RequestParam("symbolId") String symbolId)
      Deletes a symbol.
      Parameters:
      symbolId - symbol id
      Returns:
      ResponseEntity