const apiKey = "your api key here" // update with your api_key
const listId = 0 // update with the id of the list that you would like returned
const myHeaders = new Headers();
myHeaders.append('Authorization', `Bearer ${apiKey}`);
const requestOptions = {
method: 'GET',
headers: myHeaders,
redirect: 'follow'
};
fetch(`https://wiza.co/api/lists/${listId}`, requestOptions)
.then((response) => response.text())
.then((result) => console.log(result))
.catch((error) => console.error(error));{
"status": {
"code": 200,
"message": ""
},
"type": "list",
"data": {
"id": 15,
"name": "VP of Sales in San Francisco",
"status": "queued",
"stats": {
"people": 2,
"credits": {
"email_credits": 1,
"phone_credits": 1,
"export_credits": 1,
"api_credits": {
"email_credits": 2,
"phone_credits": 5,
"scrape_credits": 1,
"total": 8
}
}
},
"finished_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"enrichment_level": "partial",
"email_options": {
"accept_work": true,
"accept_personal": true,
"accept_generic": true
},
"report_type": "people"
}
}Get the list with the given id
const apiKey = "your api key here" // update with your api_key
const listId = 0 // update with the id of the list that you would like returned
const myHeaders = new Headers();
myHeaders.append('Authorization', `Bearer ${apiKey}`);
const requestOptions = {
method: 'GET',
headers: myHeaders,
redirect: 'follow'
};
fetch(`https://wiza.co/api/lists/${listId}`, requestOptions)
.then((response) => response.text())
.then((result) => console.log(result))
.catch((error) => console.error(error));{
"status": {
"code": 200,
"message": ""
},
"type": "list",
"data": {
"id": 15,
"name": "VP of Sales in San Francisco",
"status": "queued",
"stats": {
"people": 2,
"credits": {
"email_credits": 1,
"phone_credits": 1,
"export_credits": 1,
"api_credits": {
"email_credits": 2,
"phone_credits": 5,
"scrape_credits": 1,
"total": 8
}
}
},
"finished_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"enrichment_level": "partial",
"email_options": {
"accept_work": true,
"accept_personal": true,
"accept_generic": true
},
"report_type": "people"
}
}Enter your bearer token (your API key) in the Authorization header in the format Bearer {token}
id