@lap v0.3
# Machine-readable API spec. Each @endpoint block is one API call.
@api Wayback API
@base https://api.archive.org/
@version 1.0.0
@endpoints 2
@toc wayback(2)

@endpoint GET /wayback/v1/available
@required {url: any # A single URL to query.}
@optional {timestamp: any # Timestamp requested in ISO 8601 format. The following formats are acceptable:  - YYYY  - YYYY-MM  - YYYY-MM-DD  - YYYY-MM-DDTHH:mm:SSz  - YYYY-MM-DD:HH:mm+00:00, callback: any # Specifies a JavaScript function func, for a JSON-P response. When provided, results are wrapped as `callback(data)`, and the returned MIME type is application/javascript. This causes the caller to automatically run the func with the JSON results as its argument., timeout: any # Timeout is the maximum number of seconds to wait for the availability API to get its underlying results from the CDX server. The default value is 5.0., closest: any # The direction specifies whether to match archived timestamps that are before the provided one, after, or the default either (closest in either direction). Must be before, after, or either. May be overidden by individual requests., status_code: any # HTTP status codes to filter by. Only results with these codes will be returned, tag: any # The optional tag can have any value, and is returned with the results; it can be used to help collate input and output values.}
@returns(200) Nominal Availability results

@endpoint POST /wayback/v1/available
@required {url: any # A single URL to query.}
@optional {timestamp: any # Timestamp requested in ISO 8601 format. The following formats are acceptable:  - YYYY  - YYYY-MM  - YYYY-MM-DD  - YYYY-MM-DDTHH:mm:SSz  - YYYY-MM-DD:HH:mm+00:00, callback: any # Specifies a JavaScript function func, for a JSON-P response. When provided, results are wrapped as `callback(data)`, and the returned MIME type is application/javascript. This causes the caller to automatically run the func with the JSON results as its argument., timeout: any # Timeout is the maximum number of seconds to wait for the availability API to get its underlying results from the CDX server. The default value is 5.0., closest: any # The direction specifies whether to match archived timestamps that are before the provided one, after, or the default either (closest in either direction). Must be before, after, or either. May be overidden by individual requests., status_code: any # HTTP status codes to filter by. Only results with these codes will be returned, tag: any # The optional tag can have any value, and is returned with the results; it can be used to help collate input and output values., availabilty_request: [map]}
@returns(200) Nominal Availability results

@end
