File tree Expand file tree Collapse file tree 6 files changed +33
-19
lines changed
apify-api/openapi/code_samples/javascript Expand file tree Collapse file tree 6 files changed +33
-19
lines changed Original file line number Diff line number Diff line change 11import { ApifyClient } from 'apify-client' ;
22
3- const apifyClient = new ApifyClient ( { token : 'my-token' } ) ;
4- // Replace apify~my-sample-actor with your Actor's ID or technical name
5- const { items } = await apifyClient . actor ( 'apify~my-sample-actor' )
3+ const apifyClient = new ApifyClient ( {
4+ token : '<TOKEN>' ,
5+ } ) ;
6+ const { items } = await apifyClient
7+ . actor ( '<ACTOR ID>' )
68 . builds ( )
79 . list ( ) ;
810
Original file line number Diff line number Diff line change 11import { ApifyClient } from 'apify-client' ;
22
3- const apifyClient = new ApifyClient ( { token : 'my-token' } ) ;
4- // Replace apify~my-sample-actor with your Actor's ID or technical name
5- const build = await apifyClient . actor ( 'apify~my-sample-actor' ) . build ( '0.0' ) ;
3+ const apifyClient = new ApifyClient ( {
4+ token : '<TOKEN>' ,
5+ } ) ;
6+ const build = await apifyClient
7+ . actor ( '<ACTOR ID>' )
8+ . build ( '0.0' ) ;
69
710console . log ( build ) ;
Original file line number Diff line number Diff line change 11import { ApifyClient } from 'apify-client' ;
22
3- const apifyClient = new ApifyClient ( { token : 'my-token' } ) ;
4- // Replace apify~my-sample-actor with your Actor's ID or technical name
5- const { items } = await apifyClient . actor ( 'apify~my-sample-actor' )
3+ const apifyClient = new ApifyClient ( {
4+ token : '<TOKEN>' ,
5+ } ) ;
6+ const { items } = await apifyClient
7+ . actor ( '<ACTOR ID>' )
68 . runs ( )
79 . list ( ) ;
810
Original file line number Diff line number Diff line change 11import { ApifyClient } from 'apify-client' ;
22
3- const apifyClient = new ApifyClient ( { token : 'my-token' } ) ;
4- // Replace apify~my-sample-actor with your Actor's ID or technical name
5- const lastRun = await apifyClient . actor ( 'apify~my-sample-actor' ) . lastRun ( ) ;
3+ const apifyClient = new ApifyClient ( {
4+ token : '<TOKEN>' ,
5+ } ) ;
6+ const lastRun = await apifyClient
7+ . actor ( '<ACTOR ID>' )
8+ . lastRun ( ) ;
69
710console . log ( lastRun ) ;
Original file line number Diff line number Diff line change 11import { ApifyClient } from 'apify-client' ;
22
3- const apifyClient = new ApifyClient ( { token : 'my-token' } ) ;
4- // Replace apify~my-sample-actor with your Actor's ID or technical name
5- const run = await apifyClient . actor ( 'apify~my-sample-actor' )
6- . start ( /** Your Actor's input */ ) ;
3+ const apifyClient = new ApifyClient ( {
4+ token : '<TOKEN>' ,
5+ } ) ;
6+ const run = await apifyClient
7+ . actor ( '<ACTOR ID>' )
8+ . start ( { /** <ACTOR INPUT> */ } ) ;
79
810console . log ( run ) ;
Original file line number Diff line number Diff line change 11import { ApifyClient } from 'apify-client' ;
22
3- const apifyClient = new ApifyClient ( { token : 'my-token' } ) ;
4- // Replace apify~my-sample-actor with your Actor's ID or technical name
5- const { items } = await apifyClient . actor ( 'apify~my-sample-actor' )
3+ const apifyClient = new ApifyClient ( {
4+ token : '<TOKEN>' ,
5+ } ) ;
6+ const { items } = await apifyClient
7+ . actor ( '<ACTOR ID>' )
68 . webhooks ( )
79 . list ( ) ;
810
You can’t perform that action at this time.
0 commit comments