API: Processing Archiver API Requests
This document provides a guide for software developers to use the Archiver REST API.
The Archiver REST API is designed to be compatible with any REST client library and JSON parser, which exist in most languages. Examples in Python can be found here.
The sequence of steps for interacting with the Archiver API are:
- Issue an HTTP POST request to authenticate via the login endpoint. The host endpoint for the service URL will depend on whether your Archiver account is hosted within the US or EU. For US, use https://archiver.sageflo.com; for EU use https://archiver-eu.sageflo.com.
- A JSON response is returned with an authentication token, which is to be used for subsequent API requests.
- Issue an HTTP post request to the email search endpoint, along with the authentication token in an HTTP header.
- Process search results in the JSON response.
- If desired, retrieve email HTML source using resource links in the JSON search results.
- If desired, trigger an email resend using the email send endpoint.
- Repeat steps 3 – 6 as needed.
- If needed, refresh the authorization token to avoid having to re-authenticate. By default, tokens are valid for 2 hours