File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -73,14 +73,18 @@ value:
7373```js
7474// If you use our Podcast API with Node.js or browser javascript, then use the Client class.
7575const { Client } = require('podcast-api');
76+ const client = Client({
77+ apiKey: process.env.LISTEN_API_KEY || null,
78+ });
7679
7780// If you use our Podcast API with Cloudflare Workers / Pages, then use the ClientForWorkers class.
81+ // Please make sure you store LISTEN_API_KEY as a secret. See example code:
82+ // - https://github.com/ListenNotes/podcast-api-js/blob/cloudflare-workers/examples/PodcastAppForWorkers/src/index.js
7883// const { ClientForWorkers } = require('podcast-api');
79- // const Client = ClientForWorkers
84+ // const client = ClientForWorkers({
85+ // apiKey: env.LISTEN_API_KEY || null,
86+ // });
8087
81- const client = Client({
82- apiKey: process.env.LISTEN_API_KEY || null,
83- });
8488
8589client.search({
8690 q: 'elon musk',
You can’t perform that action at this time.
0 commit comments