How to setup and manage your own student discount.
Awesome, you have decided to offer a student discount. Now you want to know the best way of doing so. To get started, you will need the following:
Okay so now you know what you're going to need, let's get started.
You are going to need to start by adding a new form to your website.
This form will be used for the student to enter their student email.
Now that you have the students email, you are going to want to get just the domain part of it (this is everything after the @).
Once you have the domain you will then need to use the Email Warrant API to see if it exists in our database of verified student domains. To do this, you will need to make a GET request in the following formate:
https://api.emailwarrant.com/v1/verify.php?userID=Your User ID&apiKey=Your API Key&domain=Domain to be verified
If you’d like more details about using the API you can find them here.
Once you have sent your request, you will receive a response from Email Warrant confirming if the domain you submitted is verified by us. This response is sent back to you in JSON and looks like this:
{ "status":"success", "result":{ "domain":"verified", "type":"student", "usage":{ "remainingCalls":95281, "usedCalls":4719, "totalCalls":"100000", "renewalDate":"2020-06-12" } } }
As you can see in this response, the domain has been verified, and we have confirmed it belongs to a student.
If the domain was not recognised, you would instead receive a response like this:
{ "status":"success", "result":{ "domain":"rejected", "type":"unknown", "usage":{ "remainingCalls":45, "usedCalls":5, "totalCalls":50, "renewalDate":"May 22 2029" } } }
Now the domain has been verified; you now need to send the discount over to the student.
We always recommend sending the discount to the student email to confirm that it is their email.