Settings
Reset API Key
POST /api/reset
This endpoint allows you to reset your API key to a new, randomly generated key.
This method requires you to authenticate using your existing API key.
Headers
Authorization*
string
The existing API key.
{
"success": true,
"message": "API Key successfully reset!",
"data": "0123456789abcdef"
}CUSTOMERS MANAGEMENT
Allows you to add another client with a corresponding logo and a billing type.
Customers have the following format:
{
"id" : int64,
"name" : string,
"description" : string,
"services" : []ServiceUsed,
"currently_used" : bool,
"logo_url" : string,
"users" : []User,
"user_id" : int64,
"regex_email" : string,
"count_quotas_email_sent": int64,
"quota_email_sent" : int64,
"quota_user" : int64,
"count_quota_user" : int64,
"type_billing" : string,
"organisation" : {}Organisation,
"organisation_id" : int64,
"hash" : string
}
Get Customers
GET /api/customers
Returns a list of all customer accounts in Gottaphish.
Headers
Authorization*
string
A valid API key
Get Customer
GET /api/customers/:id
Returns a customer with the given ID.
Path Parameters
id*
integer
The customer ID
Headers
Authorization*
string
A valid API key
Create Customer
POST /api/customers/
Creates a new customer.
Headers
Authorization*
string
A valid API key
Request Body
Payload*
object
The customer to create in JSON format.
Modify Customer
PUT /api/customers/:id
Modifies a customer. This can be used to change the name, the billing type, or change the default customer.
Path Parameters
id*
string
The user ID
Headers
Authorization*
string
A valid API key
Request Body
Payload*
object
The updated customer content.
Delete Customer
DELETE /api/customers/:id
Deletes a customer.
Path Parameters
id*
string
The customer ID
Headers
Authorization*
string
A valid API key
Returns a 404 error if no customer is found with the provided ID.
USER MANAGEMENT
Gottaphish supports having multiple user accounts. Each of these accounts are separate, with their own campaigns, landing pages, scenarios, etc.
Each user account in Gottaphish is assigned a role. These are global roles that describe the user's permissions within Gottaphish.
At the time of this writing, there are two roles:
Role
Slug
Description
User
user
A non-administrative user role. Users with this role can create objects and launch campaigns.
Admin
admin
An administrative user. Users with this role can manage system-wide settings as well as other user accounts within Gottaphish.
Users have the following format:
Each Role has the following format:
Get Users
GET /api/users/
Returns a list of all user accounts in Gottaphish.
Headers
Authorization*
string
A valid API key
Get User
GET /api/users/:id
Returns a user with the given ID.
Path Parameters
id*
integer
The user ID
Headers
Authorization*
string
A valid API key
Create User
POST /api/users/
Creates a new user.
Headers
Authorization*
string
Request Body
role*
string
The role slug to use for the account
password*
string
The password to set for the account
username*
string
The username for the account
Modify User
PUT /api/users/:id
Modifies a user account. This can be used to change the role, reset the password, or change the username.
Path Parameters
id*
string
The user ID
Headers
Authorization*
string
A valid API key
Request Body
role
string
The role slug to use for the account
password
string
The password to set for the account
username*
string
The username for the account
Delete User
DELETE /api/users/:id
Deletes a user, as well as every object (landing page, template, etc.) and campaign they've created.
Path Parameters
id*
string
The user ID
Headers
Authorization*
string
A valid API key
Returns a 404 error if no user is found with the provided ID.
Last updated