Create custom market data provider

Integrate with any market provider with an available API

If you wish to create your own market data provider, you can create your own implementation of the MarketDataInterface. You can refer to any existing market data implementation as an example.

Once you've created your market data implementation, be sure add your custom provider to the Investbrain configuration file, under the interfaces section:

'interfaces' => [
    //                       *  *  *
    'custom_provider' => \App\Services\CustomProviderMarketData::class,
    //                       *  *  *
],

And add your custom provider to your .env file:

MARKET_DATA_PROVIDER=yahoo,alphavantage,custom_provider

Feel free to submit a PR with any custom providers you create.

Updated on