@lap v0.3
# Machine-readable API spec. Each @endpoint block is one API call.
@api 
@base https://run.import.io/
@version 1.0
@endpoints 2
@toc extractor(2)

@endpoint POST /extractor/{extractorId}/start
@desc Launch a crawl from an extractor that a user owns.
@required {extractorId: any # the id of the extractor to start crawling with}
@returns(200) OK
@errors {404: Unable to find supplied extractor ID., 401: User doesn't own this extractor, or doesn't have a valid session., 400: Extractor is archived or a crawl already in progress.}

@endpoint POST /extractor/{extractorId}/cancel
@desc Cancel an existing crawl.
@required {extractorId: any # extractorId}
@returns(200) OK
@errors {404: Unable to find supplied extractor ID., 401: User doesn't own this extractor, or doesn't have a valid session., 400: No in progress crawl found to cancel.}

@end
