Skip to main content
POST
/
api
/
lists
JavaScript
const apiKey = "your api key here" // update with your api_key

const myHeaders = new Headers();
myHeaders.append("Content-Type", "application/json");
myHeaders.append("Authorization", `Bearer ${apiKey}`);

const raw = JSON.stringify({
  "list": {
    "name": "List name",
    "enrichment_level": "partial",
    "email_options": {
      "accept_work": true,
      "accept_personal": true,
      "accept_generic": true
    },
    "items": [
      {
        "full_name": "Stephen Hakami",
        "company": "Wiza",
        "domain": "wiza.co"
      }, {
        "profile_url": "https://www.linkedin.com/in/stephen-hakami-5babb21b0/"
      }, {
        "email": "stephen@wiza.co"
      }
    ]
  }
});

const requestOptions = {
  method: "POST",
  headers: myHeaders,
  body: raw,
  redirect: "follow"
};

fetch("https://wiza.co/api/lists", requestOptions)
  .then((response) => response.text())
  .then((result) => console.log(result))
  .catch((error) => console.error(error));
{
  "status": {
    "code": 200,
    "message": "🧙 Wiza is working on it!"
  },
  "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"
  }
}

Authorizations

Authorization
string
header
required

Enter your bearer token (your API key) in the Authorization header in the format Bearer {token}

Body

application/json
list
object
Example:
{
"name": "VP of Sales in San Francisco",
"enrichment_level": "partial",
"email_options": {
"accept_work": true,
"accept_personal": true,
"accept_generic": true
},
"items": [
{
"full_name": "Stephen Hakami",
"company": "Wiza",
"domain": "wiza.co"
},
{
"profile_url": "https://www.linkedin.com/in/stephen-hakami-5babb21b0/"
},
{ "email": "stephen@wiza.co" }
]
}

Response

successful

status
object
type
enum<string>
Available options:
list
Example:

"list"

data
object