cURL
curl --request GET \
--url http://base.url.com/profiles/all \
--header 'x-phishy-api-key: <api-key>'import requests
url = "http://base.url.com/profiles/all"
headers = {"x-phishy-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-phishy-api-key': '<api-key>'}};
fetch('http://base.url.com/profiles/all', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://base.url.com/profiles/all",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-phishy-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "http://base.url.com/profiles/all"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-phishy-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("http://base.url.com/profiles/all")
.header("x-phishy-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("http://base.url.com/profiles/all")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["x-phishy-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"name": "<string>",
"method": "<string>",
"fromAddress": "<string>",
"mailServer": "<string>",
"mailServerPort": 123,
"customPort": false,
"useSSLTLS": false,
"lastUpdatedBy": "<string>",
"lastModified": "<string>"
}
]{
"error": 123,
"message": "<string>"
}{
"error": 403,
"message": "You do not have permission to access this resource."
}SMTP Profiles
Get All Profiles
Returns all profiles without pagination
GET
/
profiles
/
all
cURL
curl --request GET \
--url http://base.url.com/profiles/all \
--header 'x-phishy-api-key: <api-key>'import requests
url = "http://base.url.com/profiles/all"
headers = {"x-phishy-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-phishy-api-key': '<api-key>'}};
fetch('http://base.url.com/profiles/all', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "http://base.url.com/profiles/all",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-phishy-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "http://base.url.com/profiles/all"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-phishy-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("http://base.url.com/profiles/all")
.header("x-phishy-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("http://base.url.com/profiles/all")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["x-phishy-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"name": "<string>",
"method": "<string>",
"fromAddress": "<string>",
"mailServer": "<string>",
"mailServerPort": 123,
"customPort": false,
"useSSLTLS": false,
"lastUpdatedBy": "<string>",
"lastModified": "<string>"
}
]{
"error": 123,
"message": "<string>"
}{
"error": 403,
"message": "You do not have permission to access this resource."
}Authorizations
Response
An array of all profiles
Name of the user
Method used for the profile
Originating address of the profile
Mail server address used for the profile
Port used by the mail server
Indicates if a custom port is used
Indicates if SSL/TLS is used for the connection
User who last updated the profile
Date and time when the profile was last modified
⌘I
