2015-12-27 02:48:10 +00:00
{{ define "base" }}
2016-03-04 02:44:11 +00:00
<!DOCTYPE html> < html > < head > < meta charset = "utf-8" > < title > Gophish API< / title > < link rel = "stylesheet" href = "https://maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css" > < style > @ i m p o r t u r l ( ' h t t p s : / / f o n t s . g o o g l e a p i s . c o m / c s s ? f a m i l y = R o b o t o : 4 0 0 , 7 0 0 | I n c o n s o l a t a | R a l e w a y : 2 0 0 ' ) ; . h l j s - c o m m e n t , . h l j s - t i t l e { c o l o r : # 8 e 9 0 8 c } . h l j s - v a r i a b l e , . h l j s - a t t r i b u t e , . h l j s - t a g , . h l j s - r e g e x p , . r u b y . h l j s - c o n s t a n t , . x m l . h l j s - t a g . h l j s - t i t l e , . x m l . h l j s - p i , . x m l . h l j s - d o c t y p e , . h t m l . h l j s - d o c t y p e , . c s s . h l j s - i d , . c s s . h l j s - c l a s s , . c s s . h l j s - p s e u d o { c o l o r : # c 8 2 8 2 9 } . h l j s - n u m b e r , . h l j s - p r e p r o c e s s o r , . h l j s - p r a g m a , . h l j s - b u i l t _ i n , . h l j s - l i t e r a l , . h l j s - p a r a m s , . h l j s - c o n s t a n t { c o l o r : # f 5 8 7 1 f } . r u b y . h l j s - c l a s s . h l j s - t i t l e , . c s s . h l j s - r u l e s . h l j s - a t t r i b u t e { c o l o r : # e a b 7 0 0 } . h l j s - s t r i n g , . h l j s - v a l u e , . h l j s - i n h e r i t a n c e , . h l j s - h e a d e r , . r u b y . h l j s - s y m b o l , . x m l . h l j s - c d a t a { c o l o r : # 7 1 8 c 0 0 } . c s s . h l j s - h e x c o l o r { c o l o r : # 3 e 9 9 9 f } . h l j s - f u n c t i o n , . p y t h o n . h l j s - d e c o r a t o r , . p y t h o n . h l j s - t i t l e , . r u b y . h l j s - f u n c t i o n . h l j s - t i t l e , . r u b y . h l j s - t i t l e . h l j s - k e y w o r d , . p e r l . h l j s - s u b , . j a v a s c r i p t . h l j s - t i t l e , . c o f f e e s c r i p t . h l j s - t i t l e { c o l o r : # 4 2 7 1 a e } . h l j s - k e y w o r d , . j a v a s c r i p t . h l j s - f u n c t i o n { c o l o r : # 8 9 5 9 a 8 } . h l j s { d i s p l a y : b l o c k ; b a c k g r o u n d : w h i t e ; c o l o r : # 4 d 4 d 4 c ; p a d d i n g : . 5 e m } . c o f f e e s c r i p t . j a v a s c r i p t , . j a v a s c r i p t . x m l , . t e x . h l j s - f o r m u l a , . x m l . j a v a s c r i p t , . x m l . v b s c r i p t , . x m l . c s s , . x m l . h l j s - c d a t a { o p a c i t y : . 5 } . r i g h t . h l j s - c o m m e n t { c o l o r : # 9 6 9 8 9 6 } . r i g h t . c s s . h l j s - c l a s s , . r i g h t . c s s . h l j s - i d , . r i g h t . c s s . h l j s - p s e u d o , . r i g h t . h l j s - a t t r i b u t e , . r i g h t . h l j s - r e g e x p , . r i g h t . h l j s - t a g , . r i g h t . h l j s - v a r i a b l e , . r i g h t . h t m l . h l j s - d o c t y p e , . r i g h t . r u b y . h l j s - c o n s t a n t , . r i g h t . x m l . h l j s - d o c t y p e , . r i g h t . x m l . h l j s - p i , . r i g h t . x m l . h l j s - t a g . h l j s - t i t l e { c o l o r : # c 6 6 } . r i g h t . h l j s - b u i l t _ i n , . r i g h t . h l j s - c o n s t a n t , . r i g h t . h l j s - l i t e r a l , . r i g h t . h l j s - n u m b e r , . r i g h t . h l j s - p a r a m s , . r i g h t . h l j s - p r a g m a , . r i g h t . h l j s - p r e p r o c e s s o r { c o l o r : # d e 9 3 5 f } . r i g h t . c s s . h l j s - r u l e . h l j s - a t t r i b u t e , . r i g h t . r u b y . h l j s - c l a s s . h l j s - t i t l e { c o l o r : # f 0 c 6 7 4 } . r i g h t . h l j s - h e a d e r , . r i g h t . h l j s - i n h e r i t a n c e , . r i g h t . h l j s - n a m e , . r i g h t . h l j s - s t r i n g , . r i g h t . h l j s - v a l u e , . r i g h t . r u b y . h l j s - s y m b o l , . r i g h t . x m l . h l j s - c d a t a { c o l o r : # b 5 b d 6 8 } . r i g h t . c s s . h l j s - h e x c o l o r , . r i g h t . h l j s - t i t l e { c o l o r : # 8 a b e b 7 } . r i g h t . c o f f e e s c r i p t . h l j s - t i t l e , . r i g h t . h l j s - f u n c t i o n , . r i g h t . j a v a s c r i p t . h l j s - t i t l e , . r i g h t . p e r l . h l j s - s u b , . r i g h t . p y t h o n . h l j s - d e c o r a t o r , . r i g h t . p y t h o n . h l j s - t i t l e , . r i g h t . r u b y . h l j s - f u n c t i o n . h l j s - t i t l e , . r i g h t . r u b y . h l j s - t i t l e . h l j s - k e y w o r d { c o l o r : # 8 1 a 2 b e } . r i g h t . h l j s - k e y w o r d , . r i g h t . j a v a s c r i p t . h l j s - f u n c t i o n { c o l o r : # b 2 9 4 b b } . r i g h t . h l j s { d i s p l a y : b l o c k ; o v e r f l o w - x : a u t o ; b a c k g r o u n d : # 1 d 1 f 2 1 ; c o l o r : # c 5 c 8 c 6 ; p a d d i n g : . 5 e m ; - w e b k i t - t e x t - s i z e - a d j u s t : n o n e } . r i g h t . c o f f e e s c r i p t . j a v a s c r i p t , . r i g h t . j a v a s c r i p t . x m l , . r i g h t . t e x . h l j s - f o r m u l a , . r i g h t . x m l . c s s , . r i g h t . x m l . h l j s - c d a t a , . r i g h t . x m l . j a v a s c r i p t , . r i g h t . x m l . v b s c r i p t { o p a c i t y : . 5 } b o d y { c o l o r : b l a c k ; b a c k g r o u n d : w h i t e ; f o n t : 4 0 0 1 4 p x / 1 . 4 2 ' R o b o t o ' , H e l v e t i c a , s a n s - s e r i f } h e a d e r { b o r d e r - b o t t o m : 1 p x s o l i d # f 2 f 2 f 2 ; m a r g i n - b o t t o m : 1 2 p x } h 1 , h 2 , h 3 , h 4 , h 5 { c o l o r : b l a c k ; m a r g i n : 1 2 p x 0 } h 1 . p e r m a l i n k , h 2 . p e r m a l i n k , h 3 . p e r m a l i n k , h 4 . p e r m a l i n k , h 5 . p e r m a l i n k { m a r g i n - l e f t : 0 ; o p a c i t y : 0 ; t r a n s i t i o n : o p a c i t y . 2 5 s e a s e } h 1 : h o v e r . p e r m a l i n k , h 2 : h o v e r . p e r m a l i n k , h 3 : h o v e r . p e r m a l i n k , h 4 : h o v e r . p e r m a l i n k , h 5 : h o v e r . p e r m a l i n k { o p a c i t y : 1 } . t r i p l e h 1 . p e r m a l i n k , . t r i p l e h 2 . p e r m a l i n k , . t r i p l e h 3 . p e r m a l i n k , . t r i p l e h 4 . p e r m a l i n k , . t r i p l e h 5 . p e r m a l i n k { o p a c i t y : . 1 5 } . t r i p l e h 1 : h o v e r . p e r m a l i n k , . t r i p l e h 2 : h o v e r . p e r m a l i n k , . t r i p l e h 3 : h o v e r . p e r m a l i n k , . t r i p l e h 4 : h o v e r . p e r m a l i n k , . t r i p l e h 5 : h o v e r . p e r m a l i n k { o p a c i t y : . 1 5 } h 1 { f o n t : 2 0 0 3 6 p x ' R a l e w a y ' , H e l v e t i c a , s a n s - s e r i f ; f o n t - s i z e : 3 6 p x } h 2 { f o n t : 2 0 0 3 6 p x ' R a l e w a y ' , H e l v e t i c a , s a n s - s e r i f ; f o n t - s i z e : 3 0 p x } h 3 { f o n t - s i z e : 1 0 0 % ; t e x t - t r a n s f o r m : u p p e r c a s e } h 5 { f o n t - s i z e : 1 0 0 % ; f o n t - w e i g h t : n o r m a l } p { m a r g i n : 0 0 1 0 p x } p . c h o i c e s { l i n e - h e i g h t : 1 . 6 } a { c o l o r : # 4 2 8 b c a ; t e x t - d e c o r a t i o n : n o n e } l i p { m a r g i n : 0 } h r . s p l i t { b o r d e r : 0 ; h e i g h t : 1 p x ; w i d t h : 1 0 0 % ; p a d d i n g - l e f t : 6 p x ; m a r g i n : 1 2 p x a u t o ; b a c k g r o u n d - i m a g e : l i n e a r - g r a d i e n t ( t o r i g h t , r g b a ( 0 , 0 , 0 , 0 ) 2 0 % , r g b a ( 0 , 0 , 0 , 0 . 2 ) 5 1 . 4 % , r g b a ( 2 5 5 , 2 5 5 , 2 5 5 , 0 . 2 ) 5 1 . 4 % , r g b a ( 2 5 5 , 2 5 5 , 2 5 5 , 0 ) 8 0 % ) } d l d t { f l o a t : l e f t ; w i d t h : 1 3 0 p x ; c l e a r : l e f t ; t e x t - a l i g n : r i g h t ; o v e r f l o w : h i d d e n ; t e x t - o v e r f l o w : e l l i p s i s ; w h i t e - s p a c e : n o w r a p ; f o n
2016-01-12 04:29:11 +00:00
< p > These docs describe how to use the < a href = "https://github.com/gophish/gophish" > gophish< / a > API.< / p >
2015-12-26 04:09:32 +00:00
< div class = "note" >
< h2 id = "header-authorization" > Authorization < a class = "permalink" href = "#header-authorization" aria-hidden = "true" > ¶< / a > < / h2 >
< p > All API requests require the use of a generated API key. You can find your API key, or generate a new one, by navigating to the /settings endpoint, or clicking the “Settings” sidebar item.< / p >
< p > When making requests, simply append the < code > api_key=[API_KEY]< / code > as a GET parameter to authorize yourself to the API.< / p >
< pre > < code class = "language-http" > GET /api/campaigns/?api_key=12345678901234567890123456789012< / code > < / pre >
< p > If no API key is provided, you’ ll receive the following response when attempting to make requests to API endpoints:< / p >
< pre > < code class = "language-json" > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "API Key not set"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
< / span > }< / code > < / pre >
< / div >
2016-03-04 02:44:11 +00:00
< / div > < div class = "middle" > < section id = "campaigns" class = "resource-group" > < h2 class = "group-heading" > Campaigns < a href = "#campaigns" class = "permalink" > ¶ < / a > < / h2 > < / section > < / div > < div class = "middle" > < div id = "campaigns-campaigns" class = "resource" > < h3 class = "resource-heading" > Campaigns < a href = "#campaigns-campaigns" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method get" > GET< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /campaigns< / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Campaign"< / span > < / span > ,
"< span class = "hljs-attribute" > created_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > completed_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > template< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Template"< / span > < / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example email template subject"< / span > < / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "This is a test message!"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Attachment"< / span > < / span > ,
"< span class = "hljs-attribute" > content< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Hello, world!"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "text/plain"< / span >
< / span > }
]< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > page< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Page"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > status< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Emails Sent"< / span > < / span > ,
"< span class = "hljs-attribute" > results< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > email< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo@example.com"< / span > < / span > ,
"< span class = "hljs-attribute" > first_name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John"< / span > < / span > ,
"< span class = "hljs-attribute" > last_name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Doe"< / span > < / span > ,
"< span class = "hljs-attribute" > status< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Email Sent"< / span > < / span > ,
"< span class = "hljs-attribute" > ip< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "1.2.3.4"< / span > < / span > ,
"< span class = "hljs-attribute" > latitude< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 0< / span > < / span > ,
"< span class = "hljs-attribute" > longitude< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 0< / span >
< / span > }
]< / span > ,
"< span class = "hljs-attribute" > timeline< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > email< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo@example.com"< / span > < / span > ,
"< span class = "hljs-attribute" > time< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Campaign Created"< / span >
< / span > }
]< / span > ,
"< span class = "hljs-attribute" > smtp< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "smtp.example.com:25"< / span > < / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo"< / span > < / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "bar"< / span > < / span > ,
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John Doe < foo@example.com> "< / span > < / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > url< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://foo.bar"< / span >
< / span > }
]< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > []< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "campaigns-campaigns-get" class = "action get" > < h4 class = "action-heading" > < div class = "name" > Get Campaigns< / div > < a href = "#campaigns-campaigns-get" class = "method get" > GET< / a > < code class = "uri" > /campaigns< / code > < / h4 > < p > Get a list of campaigns.< / p >
< p > Campaigns object contain the resources needed for gophish to launch and track a simulated phishing campaign.< / p >
2015-12-26 04:09:32 +00:00
< p > Campaigns have the following attributes:< / p >
< ul >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > id< / code > : 1 (number, required) - Unique identifier< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > name< / code > : Example Campaign (string, required) - Title of Campaign< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
< p > < code > created_date< / code > : 2015-1-1T01:02:03.000000Z (datetime) - Date the Campaign was created< / p >
< / li >
< li >
< p > < code > completed_date< / code > : 2015-1-1T01:02:03.000000Z (datetime) - Date the Campaign was completed< / p >
< / li >
< li >
2015-12-27 02:48:10 +00:00
< p > < code > template< / code > : < a href = "#templates" > Template< / a > < / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2015-12-27 02:48:10 +00:00
< p > < code > page< / code > : < a href = "#pages" > Page< / a > (required) - Landing page for users who click the phishing link< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > status< / code > : Emails Sent (string) - The current status of the campaign< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > results< / code > : array[Result] - List of Results for the campaign< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > timeline< / code > : array[Event] - List of Events for the campaign< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-03-04 02:44:11 +00:00
< p > < code > smtp< / code > : < a href = "#sending-profiles" > SendingProfile< / a > < / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
< p > < code > url< / code > : < a href = "http://foo.bar" > http://foo.bar< / a > (required, string) - The URL used in the Template sent to us
ers< / p >
< / li >
< / ul >
2016-01-12 04:29:11 +00:00
< p > The results of the campaign are stored in the < code > results< / code > field. Each result has the following attributes:< / p >
< ul >
< li >
< p > < code > id< / code > : 1 (number, required) - Unique identifier< / p >
< / li >
< li >
< p > < code > email< / code > : < a href = "mailto:foo@example.com" > foo@example.com< / a > - Email address of the target< / p >
< / li >
< li >
< p > < code > first_name< / code > : John - First name of the target< / p >
< / li >
< li >
< p > < code > last_name< / code > : Doe - Last name of the target< / p >
< / li >
< li >
< p > < code > status< / code > : Email Sent - The status of the result< / p >
< / li >
< li >
< p > < code > ip< / code > : 1.2.3.4 - The IP address that created the event (if any)< / p >
< / li >
< li >
< p > < code > latitude< / code > : 0.0000- The latitude of the IP address< / p >
< / li >
< li >
< p > < code > longitude< / code > : 0.0000 - The longitude of the IP address< / p >
< / li >
< / ul >
< p > Each campaign also keeps a timeline of events that occur, such as clicking a link, opening an email, etc. These events each have the following attributes:< / p >
< ul >
< li >
< p > < code > email< / code > : < a href = "mailto:foo@example.com" > foo@example.com< / a > - Email address of the target< / p >
< / li >
< li >
< p > < code > time< / code > : 2015-1-1T01:02:03.000000Z (datetime) - The timestamp the event was created< / p >
< / li >
< li >
< p > < code > message< / code > : Campaign Created (string) - The event message< / p >
< / li >
< / ul >
< / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method post" > POST< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /campaigns< / span > < / div > < div class = "tabs" > < div class = "example-names" > < span > Requests< / span > < span class = "tab-button" > example 1< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Campaign"< / span > < / span > ,
"< span class = "hljs-attribute" > created_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > completed_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > template< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Template"< / span > < / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example email template subject"< / span > < / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "This is a test message!"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Attachment"< / span > < / span > ,
"< span class = "hljs-attribute" > content< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > ""< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "text/plain"< / span >
< / span > }
]< / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > page< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Page"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > status< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Emails Sent"< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > results< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > email< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo@example.com"< / span > < / span > ,
"< span class = "hljs-attribute" > first_name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John"< / span > < / span > ,
"< span class = "hljs-attribute" > last_name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Doe"< / span > < / span > ,
"< span class = "hljs-attribute" > status< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Email Sent"< / span > < / span > ,
"< span class = "hljs-attribute" > ip< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "1.2.3.4"< / span > < / span > ,
"< span class = "hljs-attribute" > latitude< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 0< / span > < / span > ,
"< span class = "hljs-attribute" > longitude< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 0< / span >
< / span > }
]< / span > ,
"< span class = "hljs-attribute" > timeline< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > email< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo@example.com"< / span > < / span > ,
"< span class = "hljs-attribute" > time< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Campaign Created"< / span >
< / span > }
]< / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > smtp< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "smtp.example.com:25"< / span > < / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo"< / span > < / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "bar"< / span > < / span > ,
2016-03-04 02:44:11 +00:00
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John Doe < foo@example.com> "< / span > < / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > url< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://foo.bar"< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 201< / span > < span class = "tab-button" > 400< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Campaign"< / span > < / span > ,
"< span class = "hljs-attribute" > created_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > completed_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > template< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Template"< / span > < / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example email template subject"< / span > < / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "This is a test message!"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Attachment"< / span > < / span > ,
"< span class = "hljs-attribute" > content< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Hello, world!"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "text/plain"< / span >
< / span > }
]< / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > page< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Page"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > status< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Emails Sent"< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > results< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > email< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo@example.com"< / span > < / span > ,
"< span class = "hljs-attribute" > first_name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John"< / span > < / span > ,
"< span class = "hljs-attribute" > last_name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Doe"< / span > < / span > ,
"< span class = "hljs-attribute" > status< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Email Sent"< / span > < / span > ,
"< span class = "hljs-attribute" > ip< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "1.2.3.4"< / span > < / span > ,
"< span class = "hljs-attribute" > latitude< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 0< / span > < / span > ,
"< span class = "hljs-attribute" > longitude< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 0< / span >
< / span > }
]< / span > ,
"< span class = "hljs-attribute" > timeline< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > email< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo@example.com"< / span > < / span > ,
"< span class = "hljs-attribute" > time< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Campaign Created"< / span >
< / span > }
]< / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > smtp< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "smtp.example.com:25"< / span > < / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo"< / span > < / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "bar"< / span > < / span > ,
2016-03-04 02:44:11 +00:00
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John Doe < foo@example.com> "< / span > < / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > url< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://foo.bar"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Title of Campaign"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > created_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Campaign was created"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > completed_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Campaign was completed"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > template< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Subject of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Raw text of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The attachments sent with the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Template was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span >
]
< / span > }< / span > ,
"< span class = "hljs-attribute" > page< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of Page"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of the landing page users hit when clicking links in the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Page was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "html"< / span >
]
< / span > }< / span > ,
"< span class = "hljs-attribute" > status< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The current status of the campaign"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > results< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The results of the campaign"< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > timeline< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The event timeline"< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > smtp< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The hostname and port for the SMTP server"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The username used for SMTP authentication"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The password used for SMTP authentication"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The \"From\" address to spoof"< / span >
2016-03-04 02:44:11 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Whether or not to ignore certificate errors"< / span >
2015-12-26 04:09:32 +00:00
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
2016-01-12 04:29:11 +00:00
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "host"< / span > ,
< span class = "hljs-string" > "username"< / span > ,
< span class = "hljs-string" > "password"< / span > ,
< span class = "hljs-string" > "from_address"< / span >
]< / span > ,
2016-03-04 02:44:11 +00:00
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The Sending Profile settings used in the campaign"< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > url< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The URL used in the Template sent to users"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "status"< / span > ,
< span class = "hljs-string" > "url"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Error message"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Any associated data"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The detailed error message"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The success status of the request"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span >
< / span > }
2016-01-12 04:29:11 +00:00
< / span > }
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "campaigns-campaigns-post" class = "action post" > < h4 class = "action-heading" > < div class = "name" > Create New Campaign< / div > < a href = "#campaigns-campaigns-post" class = "method post" > POST< / a > < code class = "uri" > /campaigns< / code > < / h4 > < p > Create a new campaign.< / p >
< / div > < / div > < hr class = "split" > < div class = "middle" > < div id = "campaigns-campaign" class = "resource" > < h3 class = "resource-heading" > Campaign < a href = "#campaigns-campaign" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method get" > GET< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /campaigns/< span class = "hljs-attribute" title = "id" > 1< / span > < / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Campaign"< / span > < / span > ,
"< span class = "hljs-attribute" > created_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > completed_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > template< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Template"< / span > < / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example email template subject"< / span > < / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "This is a test message!"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Attachment"< / span > < / span > ,
"< span class = "hljs-attribute" > content< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Hello, world!"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "text/plain"< / span >
< / span > }
]< / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > page< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Page"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > status< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Emails Sent"< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > results< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > email< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo@example.com"< / span > < / span > ,
"< span class = "hljs-attribute" > first_name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John"< / span > < / span > ,
"< span class = "hljs-attribute" > last_name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Doe"< / span > < / span > ,
"< span class = "hljs-attribute" > status< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Email Sent"< / span > < / span > ,
"< span class = "hljs-attribute" > ip< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "1.2.3.4"< / span > < / span > ,
"< span class = "hljs-attribute" > latitude< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 0< / span > < / span > ,
"< span class = "hljs-attribute" > longitude< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 0< / span >
< / span > }
]< / span > ,
"< span class = "hljs-attribute" > timeline< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > email< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo@example.com"< / span > < / span > ,
"< span class = "hljs-attribute" > time< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Campaign Created"< / span >
< / span > }
]< / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > smtp< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "smtp.example.com:25"< / span > < / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo"< / span > < / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "bar"< / span > < / span > ,
2016-03-04 02:44:11 +00:00
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John Doe < foo@example.com> "< / span > < / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > url< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://foo.bar"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Title of Campaign"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > created_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Campaign was created"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > completed_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Campaign was completed"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > template< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Subject of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Raw text of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The attachments sent with the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Template was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span >
]
< / span > }< / span > ,
"< span class = "hljs-attribute" > page< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of Page"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of the landing page users hit when clicking links in the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Page was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "html"< / span >
]
< / span > }< / span > ,
"< span class = "hljs-attribute" > status< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The current status of the campaign"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > results< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The results of the campaign"< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > timeline< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The event timeline"< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > smtp< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The hostname and port for the SMTP server"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The username used for SMTP authentication"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The password used for SMTP authentication"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The \"From\" address to spoof"< / span >
2016-03-04 02:44:11 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Whether or not to ignore certificate errors"< / span >
2015-12-26 04:09:32 +00:00
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
2016-01-12 04:29:11 +00:00
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "host"< / span > ,
< span class = "hljs-string" > "username"< / span > ,
< span class = "hljs-string" > "password"< / span > ,
< span class = "hljs-string" > "from_address"< / span >
]< / span > ,
2016-03-04 02:44:11 +00:00
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The Sending Profile settings used in the campaign"< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / span > ,
"< span class = "hljs-attribute" > url< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The URL used in the Template sent to users"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "status"< / span > ,
< span class = "hljs-string" > "url"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Campaign not found"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "campaigns-campaign-get" class = "action get" > < h4 class = "action-heading" > < div class = "name" > Get Campaign< / div > < a href = "#campaigns-campaign-get" class = "method get" > GET< / a > < code class = "uri" > /campaigns/{id}< / code > < / h4 > < p > Get a campaign by its ID.< / p >
< div class = "title" > < strong > URI Parameters< / strong > < div class = "collapse-button show" > < span class = "close" > Hide< / span > < span class = "open" > Show< / span > < / div > < / div > < div class = "collapse-content" > < dl class = "inner" > < dt > id< / dt > < dd > < code > number< / code > < span class = "required" > (required)< / span > < span class = "text-muted example" > < strong > Example: < / strong > < span > 1< / span > < / span > < p > The Campaign ID< / p >
< / dd > < / dl > < / div > < / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method delete" > DELETE< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /campaigns/< span class = "hljs-attribute" title = "id" > 1< / span > < / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Campaign deleted successfully!"< / span > < / span > ,
2015-12-27 02:48:10 +00:00
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > true< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Campaign not found"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "campaigns-campaign-delete" class = "action delete" > < h4 class = "action-heading" > < div class = "name" > Delete a Campaign< / div > < a href = "#campaigns-campaign-delete" class = "method delete" > DELETE< / a > < code class = "uri" > /campaigns/{id}< / code > < / h4 > < p > Delete a campaign by its ID.< / p >
< div class = "title" > < strong > URI Parameters< / strong > < div class = "collapse-button show" > < span class = "close" > Hide< / span > < span class = "open" > Show< / span > < / div > < / div > < div class = "collapse-content" > < dl class = "inner" > < dt > id< / dt > < dd > < code > number< / code > < span class = "required" > (required)< / span > < span class = "text-muted example" > < strong > Example: < / strong > < span > 1< / span > < / span > < p > The Campaign ID< / p >
2016-03-04 02:44:11 +00:00
< / dd > < / dl > < / div > < / div > < / div > < hr class = "split" > < div class = "middle" > < section id = "templates" class = "resource-group" > < h2 class = "group-heading" > Templates < a href = "#templates" class = "permalink" > ¶ < / a > < / h2 > < / section > < / div > < div class = "middle" > < div id = "templates-templates" class = "resource" > < h3 class = "resource-heading" > Templates < a href = "#templates-templates" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method get" > GET< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /templates< / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Template"< / span > < / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example email template subject"< / span > < / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "This is a test message!"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Attachment"< / span > < / span > ,
"< span class = "hljs-attribute" > content< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Hello, world!"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "text/plain"< / span >
< / span > }
]< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }
]< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > []< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "templates-templates-get" class = "action get" > < h4 class = "action-heading" > < div class = "name" > Get Templates< / div > < a href = "#templates-templates-get" class = "method get" > GET< / a > < code class = "uri" > /templates< / code > < / h4 > < p > Get a list of templates.< / p >
< p > Templates define what email content is sent to targets during campaigns. It contains the subject of the email as well as the HTML and text content of the email.< / p >
2015-12-26 04:09:32 +00:00
< ul >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > id< / code > : 1 (number, required) - Unique identifier< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > name< / code > : Example Template (string, required) - Name of template< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > subject< / code > : Example email template subject (string) - Subject of email sent to users< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > text< / code > : < code > This is a test message!< / code > (string) - Raw text of email sent to users< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > html< / code > : < code > < html> < head> < /head> < body> This is a test message!< /body> < /html> < / code > (string) - HTML of email sent to users< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > attachments< / code > : array[Attachment] - The attachments sent with the email template< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
< p > < code > modified_date< / code > : < code > 2015-01-01T01:02:03.000000Z< / code > (string) - Date the Template was last modified< / p >
< / li >
< / ul >
< p > You can also attach files or payloads to the emails that you send. These are attached as a list of Attachment objects.< / p >
< p > Attachments have the following attributes:< / p >
< ul >
< li >
< p > < code > id< / code > : 1 (required, number) - Unique identifier< / p >
< / li >
< li >
< p > < code > name< / code > : Example Attachment (required) - Filename of Attachment< / p >
< / li >
< li >
< p > < code > content< / code > : Base64 encoded attachment content< / p >
< / li >
< li >
< p > < code > type< / code > : < code > text/plain< / code > - MIME type of the Attachment< / p >
< / li >
< / ul >
2016-01-12 04:29:11 +00:00
< / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method post" > POST< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /templates< / span > < / div > < div class = "tabs" > < div class = "example-names" > < span > Requests< / span > < span class = "tab-button" > example 1< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Template"< / span > < / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example email template subject"< / span > < / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "This is a test message!"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Attachment"< / span > < / span > ,
"< span class = "hljs-attribute" > content< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Hello, world!"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "text/plain"< / span >
< / span > }
]< / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Subject of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Raw text of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The attachments sent with the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Template was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 201< / span > < span class = "tab-button" > 400< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Template"< / span > < / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example email template subject"< / span > < / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "This is a test message!"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Attachment"< / span > < / span > ,
"< span class = "hljs-attribute" > content< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Hello, world!"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "text/plain"< / span >
< / span > }
]< / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Subject of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Raw text of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The attachments sent with the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Template was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Error message"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Any associated data"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The detailed error message"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The success status of the request"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span >
< / span > }
2016-01-12 04:29:11 +00:00
< / span > }
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "templates-templates-post" class = "action post" > < h4 class = "action-heading" > < div class = "name" > Create New Template< / div > < a href = "#templates-templates-post" class = "method post" > POST< / a > < code class = "uri" > /templates< / code > < / h4 > < p > Create a new template< / p >
< div class = "note" >
< p > < strong > Importing an Existing Email< / strong > < / p >
< p > What better way to make pixel-perfect emails than by importing an existing email you already have sitting in your inbox?< / p >
< p > Using the < a href = "#import-email" > Import Email< / a > endpoint, you can take a raw email and import it as a template into gophish.< / p >
< / div >
< / div > < / div > < hr class = "split" > < div class = "middle" > < div id = "templates-template" class = "resource" > < h3 class = "resource-heading" > Template < a href = "#templates-template" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method get" > GET< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /templates/< span class = "hljs-attribute" title = "id" > 1< / span > < / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Template"< / span > < / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example email template subject"< / span > < / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "This is a test message!"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Attachment"< / span > < / span > ,
"< span class = "hljs-attribute" > content< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Hello, world!"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "text/plain"< / span >
< / span > }
]< / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Subject of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Raw text of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of email sent to users"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > attachments< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The attachments sent with the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Template was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Template not found"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "templates-template-get" class = "action get" > < h4 class = "action-heading" > < div class = "name" > Get Template< / div > < a href = "#templates-template-get" class = "method get" > GET< / a > < code class = "uri" > /templates/{id}< / code > < / h4 > < p > Get a template by its ID.< / p >
< div class = "title" > < strong > URI Parameters< / strong > < div class = "collapse-button show" > < span class = "close" > Hide< / span > < span class = "open" > Show< / span > < / div > < / div > < div class = "collapse-content" > < dl class = "inner" > < dt > id< / dt > < dd > < code > number< / code > < span class = "required" > (required)< / span > < span class = "text-muted example" > < strong > Example: < / strong > < span > 1< / span > < / span > < p > The Template ID< / p >
< / dd > < / dl > < / div > < / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method delete" > DELETE< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /templates/< span class = "hljs-attribute" title = "id" > 1< / span > < / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-27 02:48:10 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Template deleted successfully!"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > true< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Template not found"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "templates-template-delete" class = "action delete" > < h4 class = "action-heading" > < div class = "name" > Delete a Template< / div > < a href = "#templates-template-delete" class = "method delete" > DELETE< / a > < code class = "uri" > /templates/{id}< / code > < / h4 > < p > Delete a template by its ID.< / p >
< div class = "title" > < strong > URI Parameters< / strong > < div class = "collapse-button show" > < span class = "close" > Hide< / span > < span class = "open" > Show< / span > < / div > < / div > < div class = "collapse-content" > < dl class = "inner" > < dt > id< / dt > < dd > < code > number< / code > < span class = "required" > (required)< / span > < span class = "text-muted example" > < strong > Example: < / strong > < span > 1< / span > < / span > < p > The Template ID< / p >
2016-03-04 02:44:11 +00:00
< / dd > < / dl > < / div > < / div > < / div > < hr class = "split" > < div class = "middle" > < section id = "groups" class = "resource-group" > < h2 class = "group-heading" > Groups < a href = "#groups" class = "permalink" > ¶ < / a > < / h2 > < / section > < / div > < div class = "middle" > < div id = "groups-groups" class = "resource" > < h3 class = "resource-heading" > Groups < a href = "#groups-groups" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method get" > GET< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /groups< / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Group"< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
"< span class = "hljs-attribute" > targets< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array[Target]"< / span >
< / span > }
]< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > []< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "groups-groups-get" class = "action get" > < h4 class = "action-heading" > < div class = "name" > Get Groups< / div > < a href = "#groups-groups-get" class = "method get" > GET< / a > < code class = "uri" > /groups< / code > < / h4 > < p > Get a list of groups.< / p >
< p > Groups contain the details for one or more users targeted in the simulated phishing campaign. Groups contain the following attributes:< / p >
2015-12-26 04:09:32 +00:00
< ul >
< li >
< p > < code > id< / code > : 1 (required, number) - Unique identifier< / p >
< / li >
< li >
< p > < code > name< / code > : Example Group (required) - Name of the Group< / p >
< / li >
< li >
< p > < code > modified_date< / code > : < code > 2015-01-01T01:02:03.000000Z< / code > (string) - Date the Group was last modified< / p >
< / li >
< li >
2016-01-12 04:29:11 +00:00
< p > < code > targets< / code > : Attributes (array[Target]) (required) - The targets in the group< / p >
2015-12-26 04:09:32 +00:00
< / li >
< / ul >
< p > Each target contains the following attributes:< / p >
< ul >
< li >
< p > < code > id< / code > : 1 (required, number) - Unique identifier< / p >
< / li >
< li >
< p > < code > first_name< / code > : John - First name of Target< / p >
< / li >
< li >
< p > < code > last_name< / code > : Doe - Last name of Target< / p >
< / li >
< li >
< p > < code > email< / code > : < a href = "mailto:john.doe@example.com" > john.doe@example.com< / a > - Email address of Target< / p >
< / li >
< li >
< p > < code > position< / code > : System Administrator - Company position of the Target< / p >
< / li >
< / ul >
2015-12-27 02:48:10 +00:00
< div class = "note" >
2016-01-12 04:29:11 +00:00
< p > < strong > Have A Lot of Users to Import?< / strong > < / p >
2015-12-27 02:48:10 +00:00
< p > If you have all your targets in a CSV file, you can bulk import them into a group using the < a href = "#import-group" > Import CSV< / a > endpoint.< / p >
< p > In the future, we plan to add other importation methods to make setting up groups a breeze.< / p >
< / div >
2016-01-12 04:29:11 +00:00
< / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method post" > POST< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /groups< / span > < / div > < div class = "tabs" > < div class = "example-names" > < span > Requests< / span > < span class = "tab-button" > example 1< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Group"< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > targets< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array[Target]"< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of the Group"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Group was last modified"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > targets< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The targets in the group"< / span >
2015-12-26 04:09:32 +00:00
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
2016-01-12 04:29:11 +00:00
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "targets"< / span >
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 201< / span > < span class = "tab-button" > 400< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Group"< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > targets< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array[Target]"< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of the Group"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Group was last modified"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > targets< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The targets in the group"< / span >
2015-12-26 04:09:32 +00:00
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
2016-01-12 04:29:11 +00:00
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "targets"< / span >
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Error message"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Any associated data"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The detailed error message"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The success status of the request"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span >
< / span > }
2016-01-12 04:29:11 +00:00
< / span > }
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "groups-groups-post" class = "action post" > < h4 class = "action-heading" > < div class = "name" > Create New Group< / div > < a href = "#groups-groups-post" class = "method post" > POST< / a > < code class = "uri" > /groups< / code > < / h4 > < p > Create a new group< / p >
< / div > < / div > < hr class = "split" > < div class = "middle" > < div id = "groups-group" class = "resource" > < h3 class = "resource-heading" > Group < a href = "#groups-group" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method get" > GET< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /groups/< span class = "hljs-attribute" title = "id" > 1< / span > < / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Group"< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span > < / span > ,
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > targets< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array[Target]"< / span >
2015-12-26 04:09:32 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of the Group"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Group was last modified"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > targets< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The targets in the group"< / span >
2015-12-26 04:09:32 +00:00
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
2016-01-12 04:29:11 +00:00
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "targets"< / span >
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Group not found"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "groups-group-get" class = "action get" > < h4 class = "action-heading" > < div class = "name" > Get Group< / div > < a href = "#groups-group-get" class = "method get" > GET< / a > < code class = "uri" > /groups/{id}< / code > < / h4 > < p > Get a group by its ID.< / p >
< div class = "title" > < strong > URI Parameters< / strong > < div class = "collapse-button show" > < span class = "close" > Hide< / span > < span class = "open" > Show< / span > < / div > < / div > < div class = "collapse-content" > < dl class = "inner" > < dt > id< / dt > < dd > < code > number< / code > < span class = "required" > (required)< / span > < span class = "text-muted example" > < strong > Example: < / strong > < span > 1< / span > < / span > < p > The Group ID< / p >
< / dd > < / dl > < / div > < / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method delete" > DELETE< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /groups/< span class = "hljs-attribute" title = "id" > 1< / span > < / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-27 02:48:10 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Group deleted successfully!"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > true< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Group not found"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "groups-group-delete" class = "action delete" > < h4 class = "action-heading" > < div class = "name" > Delete a Group< / div > < a href = "#groups-group-delete" class = "method delete" > DELETE< / a > < code class = "uri" > /groups/{id}< / code > < / h4 > < p > Delete a Group by its ID.< / p >
< div class = "title" > < strong > URI Parameters< / strong > < div class = "collapse-button show" > < span class = "close" > Hide< / span > < span class = "open" > Show< / span > < / div > < / div > < div class = "collapse-content" > < dl class = "inner" > < dt > id< / dt > < dd > < code > number< / code > < span class = "required" > (required)< / span > < span class = "text-muted example" > < strong > Example: < / strong > < span > 1< / span > < / span > < p > The Template ID< / p >
2016-03-04 02:44:11 +00:00
< / dd > < / dl > < / div > < / div > < / div > < hr class = "split" > < div class = "middle" > < section id = "sending-profiles" class = "resource-group" > < h2 class = "group-heading" > Sending Profiles < a href = "#sending-profiles" class = "permalink" > ¶ < / a > < / h2 > < / section > < / div > < div class = "middle" > < div id = "sending-profiles-sending-profiles" class = "resource" > < h3 class = "resource-heading" > Sending Profiles < a href = "#sending-profiles-sending-profiles" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method get" > GET< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /smtp< / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > [
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "smtp.example.com:25"< / span > < / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo"< / span > < / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "bar"< / span > < / span > ,
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John Doe < foo@example.com> "< / span > < / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span >
< / span > }
]< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > []< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "sending-profiles-sending-profiles-get" class = "action get" > < h4 class = "action-heading" > < div class = "name" > Get Sending Profiles< / div > < a href = "#sending-profiles-sending-profiles-get" class = "method get" > GET< / a > < code class = "uri" > /smtp< / code > < / h4 > < p > Get a list of sending profiles.< / p >
< p > Sending profiles contain the details for SMTP or other settings used to control how emails are sent in campaigns. Sending profiles contain the following attributes:< / p >
2015-12-26 04:09:32 +00:00
< ul >
< li >
< p > < code > id< / code > : 1 (required, number) - Unique identifier< / p >
< / li >
< li >
2016-03-04 02:44:11 +00:00
< p > < code > name< / code > : Example Profile (string, required) - Name of the Sending Profile< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-03-04 02:44:11 +00:00
< p > < code > interface< / code > : SMTP (string) - Interface type of the sending profile. By default, this is “SMTP”< / p >
2015-12-26 04:09:32 +00:00
< / li >
< li >
2016-03-04 02:44:11 +00:00
< p > < code > host< / code > : 1.1.1.1:25 (string, required) - The hostname:port for the SMTP configuration< / p >
< / li >
< li >
< p > < code > username< / code > : foo (string) - The username to authenticate to the SMTP server (optional)< / p >
< / li >
< li >
< p > < code > password< / code > : bar (string) - The password to authenticate to the SMTP server (optional)< / p >
< / li >
< li >
< p > < code > from_address< / code > : Foo Bar < a href = "mailto:foo.bar@example.com" > foo.bar@example.com< / a > (string) - The email address to use in the “From” header. This is typically used to spoof email addresses< / p >
< / li >
< li >
< p > < code > ignore_cert_errors< / code > : false (boolean) - Whether or not to disable certificate validation when connecting to the SMTP server via TLS< / p >
< / li >
< li >
< p > < code > modified_date< / code > : < code > 2015-01-01T01:02:03.000000Z< / code > (string) - Date the Group was last modified< / p >
2015-12-26 04:09:32 +00:00
< / li >
< / ul >
2015-12-27 02:48:10 +00:00
< div class = "note" >
2016-03-04 02:44:11 +00:00
< p > < strong > Receiving Certificate Errors?< / strong > < / p >
< p > It’ s common to have an SMTP server that is configured using a self-signed or otherwise untrusted SSL certficate. To avoid errors when connecting to the server, set < code > ignore_cert_errors< / code > to “true”.< / p >
2015-12-27 02:48:10 +00:00
< / div >
2016-03-04 02:44:11 +00:00
< / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method post" > POST< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /smtp< / span > < / div > < div class = "tabs" > < div class = "example-names" > < span > Requests< / span > < span class = "tab-button" > example 1< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "smtp.example.com:25"< / span > < / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo"< / span > < / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "bar"< / span > < / span > ,
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John Doe < foo@example.com> "< / span > < / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The hostname and port for the SMTP server"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The username used for SMTP authentication"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The password used for SMTP authentication"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The \"From\" address to spoof"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Whether or not to ignore certificate errors"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "host"< / span > ,
< span class = "hljs-string" > "username"< / span > ,
< span class = "hljs-string" > "password"< / span > ,
< span class = "hljs-string" > "from_address"< / span >
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 201< / span > < span class = "tab-button" > 400< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "smtp.example.com:25"< / span > < / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo"< / span > < / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "bar"< / span > < / span > ,
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John Doe < foo@example.com> "< / span > < / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The hostname and port for the SMTP server"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The username used for SMTP authentication"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The password used for SMTP authentication"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The \"From\" address to spoof"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Whether or not to ignore certificate errors"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "host"< / span > ,
< span class = "hljs-string" > "username"< / span > ,
< span class = "hljs-string" > "password"< / span > ,
< span class = "hljs-string" > "from_address"< / span >
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Error message"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Any associated data"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The detailed error message"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The success status of the request"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span >
< / span > }
< / span > }
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "sending-profiles-sending-profiles-post" class = "action post" > < h4 class = "action-heading" > < div class = "name" > Create New Sending Profile< / div > < a href = "#sending-profiles-sending-profiles-post" class = "method post" > POST< / a > < code class = "uri" > /smtp< / code > < / h4 > < p > Create a new sending profile< / p >
< / div > < / div > < hr class = "split" > < div class = "middle" > < div id = "sending-profiles-sending-profile" class = "resource" > < h3 class = "resource-heading" > Sending Profile < a href = "#sending-profiles-sending-profile" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method get" > GET< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /smtp/< span class = "hljs-attribute" title = "id" > 1< / span > < / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "smtp.example.com:25"< / span > < / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "foo"< / span > < / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "bar"< / span > < / span > ,
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John Doe < foo@example.com> "< / span > < / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > host< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The hostname and port for the SMTP server"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > username< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The username used for SMTP authentication"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > password< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The password used for SMTP authentication"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > from_address< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The \"From\" address to spoof"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > ignore_cert_errors< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Whether or not to ignore certificate errors"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "host"< / span > ,
< span class = "hljs-string" > "username"< / span > ,
< span class = "hljs-string" > "password"< / span > ,
< span class = "hljs-string" > "from_address"< / span >
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "SMTP not found"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "sending-profiles-sending-profile-get" class = "action get" > < h4 class = "action-heading" > < div class = "name" > Get Sending Profile< / div > < a href = "#sending-profiles-sending-profile-get" class = "method get" > GET< / a > < code class = "uri" > /smtp/{id}< / code > < / h4 > < p > Get a sending profile by its ID.< / p >
< div class = "title" > < strong > URI Parameters< / strong > < div class = "collapse-button show" > < span class = "close" > Hide< / span > < span class = "open" > Show< / span > < / div > < / div > < div class = "collapse-content" > < dl class = "inner" > < dt > id< / dt > < dd > < code > number< / code > < span class = "required" > (required)< / span > < span class = "text-muted example" > < strong > Example: < / strong > < span > 1< / span > < / span > < p > The sending profile ID< / p >
< / dd > < / dl > < / div > < / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method delete" > DELETE< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /smtp/< span class = "hljs-attribute" title = "id" > 1< / span > < / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "SMTP deleted successfully!"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > true< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "SMTP not found"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "sending-profiles-sending-profile-delete" class = "action delete" > < h4 class = "action-heading" > < div class = "name" > Delete a Sending Profile< / div > < a href = "#sending-profiles-sending-profile-delete" class = "method delete" > DELETE< / a > < code class = "uri" > /smtp/{id}< / code > < / h4 > < p > Delete a Sending Profile by its ID.< / p >
< div class = "title" > < strong > URI Parameters< / strong > < div class = "collapse-button show" > < span class = "close" > Hide< / span > < span class = "open" > Show< / span > < / div > < / div > < div class = "collapse-content" > < dl class = "inner" > < dt > id< / dt > < dd > < code > number< / code > < span class = "required" > (required)< / span > < span class = "text-muted example" > < strong > Example: < / strong > < span > 1< / span > < / span > < p > The Sending Profile ID< / p >
< / dd > < / dl > < / div > < / div > < / div > < hr class = "split" > < div class = "middle" > < section id = "pages" class = "resource-group" > < h2 class = "group-heading" > Pages < a href = "#pages" class = "permalink" > ¶ < / a > < / h2 > < / section > < / div > < div class = "middle" > < div id = "pages-pages" class = "resource" > < h3 class = "resource-heading" > Pages < a href = "#pages-pages" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method get" > GET< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /pages< / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > [
2015-12-26 04:09:32 +00:00
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Page"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }
]< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span >
2016-03-04 02:44:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > []< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "pages-pages-get" class = "action get" > < h4 class = "action-heading" > < div class = "name" > Get Pages< / div > < a href = "#pages-pages-get" class = "method get" > GET< / a > < code class = "uri" > /pages< / code > < / h4 > < p > Get a list of pages.
Pages are the HTML page that a user lands on after clicking on a phishing link.< / p >
< ul >
< li >
< p > < code > id< / code > : 1 (required, number) - Unique identifier< / p >
< / li >
< li >
< p > < code > name< / code > : Example Page (required, string) - Name of Page< / p >
< / li >
< li >
< p > < code > html< / code > : < code > < html> < head> < /head> < body> This is a test message!< /body> < /html> < / code > (required, string) - HTML of the landing page users hit when clicking links in the email template< / p >
< / li >
< li >
< p > < code > modified_date< / code > : < code > 2015-01-01T01:02:03.000000Z< / code > (string) - Date the Page was last modified< / p >
< / li >
< / ul >
< div class = "note" >
< p > < strong > Importing a Site< / strong > < / p >
< p > Let gophish do the hard work for you in importing a site. By using the < a href = "#import-site" > Import Site< / a > endpoint, you can simply give gophish a URL and have the site imported for you.< / p >
< / div >
2016-01-12 04:29:11 +00:00
< / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method post" > POST< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /pages< / span > < / div > < div class = "tabs" > < div class = "example-names" > < span > Requests< / span > < span class = "tab-button" > example 1< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Page"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of Page"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of the landing page users hit when clicking links in the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Page was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "html"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 201< / span > < span class = "tab-button" > 400< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Page"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of Page"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of the landing page users hit when clicking links in the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Page was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "html"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Error message"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Any associated data"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The detailed error message"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The success status of the request"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span >
< / span > }
2016-01-12 04:29:11 +00:00
< / span > }
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "pages-pages-post" class = "action post" > < h4 class = "action-heading" > < div class = "name" > Create New Page< / div > < a href = "#pages-pages-post" class = "method post" > POST< / a > < code class = "uri" > /pages< / code > < / h4 > < p > Create a new page< / p >
< / div > < / div > < hr class = "split" > < div class = "middle" > < div id = "pages-page" class = "resource" > < h3 class = "resource-heading" > Page < a href = "#pages-page" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method get" > GET< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /pages/< span class = "hljs-attribute" title = "id" > 1< / span > < / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Page"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of Page"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of the landing page users hit when clicking links in the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Page was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "html"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Page not found"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "pages-page-get" class = "action get" > < h4 class = "action-heading" > < div class = "name" > Get Page< / div > < a href = "#pages-page-get" class = "method get" > GET< / a > < code class = "uri" > /pages/{id}< / code > < / h4 > < p > Get a page by its ID.< / p >
< div class = "title" > < strong > URI Parameters< / strong > < div class = "collapse-button show" > < span class = "close" > Hide< / span > < span class = "open" > Show< / span > < / div > < / div > < div class = "collapse-content" > < dl class = "inner" > < dt > id< / dt > < dd > < code > number< / code > < span class = "required" > (required)< / span > < span class = "text-muted example" > < strong > Example: < / strong > < span > 1< / span > < / span > < p > The Page ID< / p >
< / dd > < / dl > < / div > < / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method put" > PUT< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /pages< / span > < / div > < div class = "tabs" > < div class = "example-names" > < span > Requests< / span > < span class = "tab-button" > example 1< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Page"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of Page"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of the landing page users hit when clicking links in the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Page was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "html"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < span class = "tab-button" > 400< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Example Page"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "< html> < head> < /head> < body> This is a test message!< /body> < /html> "< / span > < / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "2015-01-01T01:02:03.000000Z"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "number"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Unique identifier"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > name< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Name of Page"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of the landing page users hit when clicking links in the email template"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > modified_date< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Date the Page was last modified"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "id"< / span > ,
< span class = "hljs-string" > "name"< / span > ,
< span class = "hljs-string" > "html"< / span >
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-27 02:48:10 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Page not found"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Error message"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Any associated data"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The detailed error message"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The success status of the request"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span >
< / span > }
< / span > }
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "pages-page-put" class = "action put" > < h4 class = "action-heading" > < div class = "name" > Put Page< / div > < a href = "#pages-page-put" class = "method put" > PUT< / a > < code class = "uri" > /pages< / code > < / h4 > < p > Modify a page by its ID.< / p >
< / div > < / div > < hr class = "split" > < div class = "right" > < div class = "definition" > < span class = "method delete" > DELETE< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /pages/< span class = "hljs-attribute" title = "id" > 1< / span > < / span > < / div > < div class = "tabs" > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 200< / span > < span class = "tab-button" > 404< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-27 02:48:10 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Page deleted successfully!"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > true< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-27 02:48:10 +00:00
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Page not found"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > null< / span >
2016-01-12 04:29:11 +00:00
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "pages-page-delete" class = "action delete" > < h4 class = "action-heading" > < div class = "name" > Delete a Page< / div > < a href = "#pages-page-delete" class = "method delete" > DELETE< / a > < code class = "uri" > /pages/{id}< / code > < / h4 > < p > Delete a page by its ID.< / p >
< div class = "title" > < strong > URI Parameters< / strong > < div class = "collapse-button show" > < span class = "close" > Hide< / span > < span class = "open" > Show< / span > < / div > < / div > < div class = "collapse-content" > < dl class = "inner" > < dt > id< / dt > < dd > < code > number< / code > < span class = "required" > (required)< / span > < span class = "text-muted example" > < strong > Example: < / strong > < span > 1< / span > < / span > < p > The Page ID< / p >
< / dd > < / dl > < / div > < / div > < / div > < hr class = "split" > < div class = "middle" > < section id = "import" class = "resource-group" > < h2 class = "group-heading" > Import < a href = "#import" class = "permalink" > ¶ < / a > < / h2 > < p > Import functions facilitate the ability to import emails, groups and more using simple interfaces.< / p >
< / section > < / div > < div class = "middle" > < div id = "import-group" class = "resource" > < h3 class = "resource-heading" > Group < a href = "#import-group" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method post" > POST< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /import/group< / span > < / div > < div class = "tabs" > < div class = "example-names" > < span > Requests< / span > < span class = "tab-button" > example 1< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > multipart/form-data; boundary=----BOUNDARY< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > ------BOUNDARY
2015-12-26 04:42:59 +00:00
Content-Disposition: form-data; name=< span class = "hljs-string" > "files[]"< / span > ; filename=< span class = "hljs-string" > "filename.csv"< / span >
Content-Type: application/vnd.ms-excel
[File Content]
2016-01-12 04:29:11 +00:00
------BOUNDARY< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 201< / span > < span class = "tab-button" > 400< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > [
2015-12-26 04:42:59 +00:00
{
"< span class = "hljs-attribute" > id< / span > ": < span class = "hljs-value" > < span class = "hljs-number" > 1< / span > < / span > ,
"< span class = "hljs-attribute" > first_name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "John"< / span > < / span > ,
"< span class = "hljs-attribute" > last_name< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Doe"< / span > < / span > ,
"< span class = "hljs-attribute" > email< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "john.doe@example.com"< / span > < / span > ,
"< span class = "hljs-attribute" > position< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "System Administrator"< / span >
< / span > }
]< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "array"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Error message"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Any associated data"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The detailed error message"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The success status of the request"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span >
< / span > }
2016-01-12 04:29:11 +00:00
< / span > }
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "import-group-post" class = "action post" > < h4 class = "action-heading" > < div class = "name" > Import a Group< / div > < a href = "#import-group-post" class = "method post" > POST< / a > < code class = "uri" > /import/group< / code > < / h4 > < p > This endpoint allows you to import a group from a CSV.< / p >
< p > The fields expected in the CSV are as follows:< / p >
< ul >
< li >
< p > First Name< / p >
< / li >
< li >
< p > Last Name< / p >
< / li >
< li >
< p > Position< / p >
< / li >
< li >
< p > Email< / p >
< / li >
< li >
< p > Company< / p >
< / li >
< / ul >
< / div > < / div > < hr class = "split" > < div class = "middle" > < div id = "import-email" class = "resource" > < h3 class = "resource-heading" > Email < a href = "#import-email" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method post" > POST< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /import/email< / span > < / div > < div class = "tabs" > < div class = "example-names" > < span > Requests< / span > < span class = "tab-button" > example 1< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > text/plain< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > MIME-Version: 1.0
2015-12-26 04:09:32 +00:00
Date: Fri, 25 Dec 2015 21:22:28 -0600
Subject: Foo Bar
From: John Doe < span class = "hljs-tag" > < < span class = "hljs-title" > john.doe@example.com< / span > > < / span >
To: Jane Doe < span class = "hljs-tag" > < < span class = "hljs-title" > jane.doe@example.com< / span > > < / span >
Content-Type: multipart/alternative; boundary=14dae9473639dc6b2a0527c4945f
--14dae9473639dc6b2a0527c4945f
Content-Type: text/plain; charset=UTF-8
Foo bar
--14dae9473639dc6b2a0527c4945f
Content-Type: text/html; charset=UTF-8
< span class = "hljs-tag" > < < span class = "hljs-title" > div< / span > < span class = "hljs-attribute" > dir< / span > =< span class = "hljs-value" > "ltr"< / span > > < / span > Foo bar< span class = "hljs-tag" > < /< span class = "hljs-title" > div< / span > > < / span >
2016-01-12 04:29:11 +00:00
--14dae9473639dc6b2a0527c4945f--< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 201< / span > < span class = "tab-button" > 400< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Foo bar"< / span > < / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "\"\\u003cdiv\\u003eFoo bar\\u003c/div\\u003e\""< / span > < / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Foo Bar"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > text< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The email text part"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The email HTML part"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > subject< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The email subject"< / span >
< / span > }
2016-01-12 04:29:11 +00:00
< / span > }
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Error message"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Any associated data"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The detailed error message"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The success status of the request"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span >
< / span > }
2016-01-12 04:29:11 +00:00
< / span > }
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "import-email-post" class = "action post" > < h4 class = "action-heading" > < div class = "name" > Import an Email< / div > < a href = "#import-email-post" class = "method post" > POST< / a > < code class = "uri" > /import/email< / code > < / h4 > < p > This endpoint allows you to parse and import an email in RFC 5322 format.< / p >
< p > You can use this endpoint to easily import an email that you have received legitimately to re-use it for simulated phishing.< / p >
< / div > < / div > < hr class = "split" > < div class = "middle" > < div id = "import-site" class = "resource" > < h3 class = "resource-heading" > Site < a href = "#import-site" class = "permalink" > ¶ < / a > < / h3 > < / div > < / div > < div class = "right" > < div class = "definition" > < span class = "method post" > POST< / span > < span class = "uri" > < span class = "hostname" > http://localhost:3333/api< / span > /import/site< / span > < / div > < div class = "tabs" > < div class = "example-names" > < span > Requests< / span > < span class = "tab-button" > example 1< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > url< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://foo.bar"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > url< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The URL to be retrieved"< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "url"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < div class = "tabs" > < div class = "example-names" > < span > Responses< / span > < span class = "tab-button" > 201< / span > < span class = "tab-button" > 400< / span > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
2015-12-26 04:09:32 +00:00
"html": "< span class = "hljs-tag" > < < span class = "hljs-title" > html< / span > > < / span > < span class = "hljs-tag" > < < span class = "hljs-title" > head< / span > > < / span > < span class = "hljs-tag" > < /< span class = "hljs-title" > head< / span > > < / span > < span class = "hljs-tag" > < < span class = "hljs-title" > body< / span > > < / span > This is a test message!< span class = "hljs-tag" > < /< span class = "hljs-title" > body< / span > > < / span > < span class = "hljs-tag" > < /< span class = "hljs-title" > html< / span > > < / span > "
}< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > html< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "HTML of the requested URL."< / span >
< / span > }
< / span > }< / span > ,
"< span class = "hljs-attribute" > required< / span > ": < span class = "hljs-value" > [
< span class = "hljs-string" > "html"< / span >
2016-01-12 04:29:11 +00:00
]
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < div class = "tab" > < div > < div class = "inner" > < h5 > Headers< / h5 > < pre > < code > < span class = "hljs-attribute" > Content-Type< / span > : < span class = "hljs-string" > application/json< / span > < / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Body< / h5 > < pre > < code > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Error message"< / span > < / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > < span class = "hljs-literal" > false< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "Any associated data"< / span >
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < h5 > Schema< / h5 > < pre > < code > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > $schema< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "http://json-schema.org/draft-04/schema#"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "object"< / span > < / span > ,
"< span class = "hljs-attribute" > properties< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > message< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span > < / span > ,
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The detailed error message"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > success< / span > ": < span class = "hljs-value" > {
2016-01-12 04:29:11 +00:00
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "boolean"< / span > < / span > ,
2015-12-26 04:09:32 +00:00
"< span class = "hljs-attribute" > description< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "The success status of the request"< / span >
< / span > }< / span > ,
"< span class = "hljs-attribute" > data< / span > ": < span class = "hljs-value" > {
"< span class = "hljs-attribute" > type< / span > ": < span class = "hljs-value" > < span class = "hljs-string" > "string"< / span >
< / span > }
2016-01-12 04:29:11 +00:00
< / span > }
< / span > }< / code > < / pre > < div style = "height: 1px;" > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < / div > < div class = "middle" > < div id = "import-site-post" class = "action post" > < h4 class = "action-heading" > < div class = "name" > Import a Site< / div > < a href = "#import-site-post" class = "method post" > POST< / a > < code class = "uri" > /import/site< / code > < / h4 > < p > Imports a site via the URL. This causes gophish to reach out to the site and pull down the HTML of the URL given.< / p >
< p > To keep styles, images, and Javascript setup and working, gophish adds a < code > base< / code > tag to the returned HTML pointing to the original site.< / p >
2016-03-04 02:44:11 +00:00
< / div > < / div > < hr class = "split" > < div class = "middle" > < p style = "text-align: center;" class = "text-muted" > Generated by < a href = "https://github.com/danielgtaylor/aglio" class = "aglio" > aglio< / a > on 04 Mar 2016< / p > < / div > < / div > < / div > < / div > < script > / * e s l i n t - e n v b r o w s e r * /
2015-12-26 04:09:32 +00:00
/* eslint quotes: [2, "single"] */
'use strict';
/*
Determine if a string ends with another string.
*/
function endsWith(str, suffix) {
return str.indexOf(suffix, str.length - suffix.length) !== -1;
}
2016-01-12 04:29:11 +00:00
/*
Get a list of direct child elements by class name.
*/
function childrenByClass(element, name) {
var filtered = [];
for (var i = 0; i < element.children.length ; i + + ) {
var child = element.children[i];
var classNames = child.className.split(' ');
if (classNames.indexOf(name) !== -1) {
filtered.push(child);
}
}
return filtered;
}
2015-12-26 04:09:32 +00:00
/*
Get an array [width, height] of the window.
*/
function getWindowDimensions() {
var w = window,
d = document,
e = d.documentElement,
g = d.body,
x = w.innerWidth || e.clientWidth || g.clientWidth,
y = w.innerHeight || e.clientHeight || g.clientHeight;
return [x, y];
}
/*
Collapse or show a request/response example.
*/
function toggleCollapseButton(event) {
var button = event.target.parentNode;
var content = button.parentNode.nextSibling;
var inner = content.children[0];
if (button.className.indexOf('collapse-button') === -1) {
// Clicked without hitting the right element?
return;
}
if (content.style.maxHeight & & content.style.maxHeight !== '0px') {
// Currently showing, so let's hide it
button.className = 'collapse-button';
content.style.maxHeight = '0px';
} else {
// Currently hidden, so let's show it
button.className = 'collapse-button show';
content.style.maxHeight = inner.offsetHeight + 12 + 'px';
}
}
2016-01-12 04:29:11 +00:00
function toggleTabButton(event) {
var i, index;
var button = event.target;
// Get index of the current button.
var buttons = childrenByClass(button.parentNode, 'tab-button');
for (i = 0; i < buttons.length ; i + + ) {
if (buttons[i] === button) {
index = i;
button.className = 'tab-button active';
} else {
buttons[i].className = 'tab-button';
}
}
// Hide other tabs and show this one.
var tabs = childrenByClass(button.parentNode.parentNode, 'tab');
for (i = 0; i < tabs.length ; i + + ) {
if (i === index) {
tabs[i].style.display = 'block';
} else {
tabs[i].style.display = 'none';
}
}
}
2015-12-26 04:09:32 +00:00
/*
Collapse or show a navigation menu. It will not be hidden unless it
is currently selected or `force` has been passed.
*/
function toggleCollapseNav(event, force) {
var heading = event.target.parentNode;
var content = heading.nextSibling;
var inner = content.children[0];
if (heading.className.indexOf('heading') === -1) {
// Clicked without hitting the right element?
return;
}
if (content.style.maxHeight & & content.style.maxHeight !== '0px') {
// Currently showing, so let's hide it, but only if this nav item
// is already selected. This prevents newly selected items from
// collapsing in an annoying fashion.
if (force || window.location.hash & & endsWith(event.target.href, window.location.hash)) {
content.style.maxHeight = '0px';
}
} else {
// Currently hidden, so let's show it
content.style.maxHeight = inner.offsetHeight + 12 + 'px';
}
}
/*
Refresh the page after a live update from the server. This only
works in live preview mode (using the `--server` parameter).
*/
function refresh(body) {
document.querySelector('body').className = 'preload';
document.body.innerHTML = body;
// Re-initialize the page
init();
autoCollapse();
document.querySelector('body').className = '';
}
/*
Determine which navigation items should be auto-collapsed to show as many
as possible on the screen, based on the current window height. This also
collapses them.
*/
function autoCollapse() {
var windowHeight = getWindowDimensions()[1];
var itemsHeight = 64; /* Account for some padding */
var itemsArray = Array.prototype.slice.call(
document.querySelectorAll('nav .resource-group .heading'));
// Get the total height of the navigation items
itemsArray.forEach(function (item) {
itemsHeight += item.parentNode.offsetHeight;
});
// Should we auto-collapse any nav items? Try to find the smallest item
// that can be collapsed to show all items on the screen. If not possible,
// then collapse the largest item and do it again. First, sort the items
// by height from smallest to largest.
var sortedItems = itemsArray.sort(function (a, b) {
return a.parentNode.offsetHeight - b.parentNode.offsetHeight;
});
while (sortedItems.length & & itemsHeight > windowHeight) {
for (var i = 0; i < sortedItems.length ; i + + ) {
// Will collapsing this item help?
var itemHeight = sortedItems[i].nextSibling.offsetHeight;
if ((itemsHeight - itemHeight < = windowHeight) || i === sortedItems.length - 1) {
// It will, so let's collapse it, remove its content height from
// our total and then remove it from our list of candidates
// that can be collapsed.
itemsHeight -= itemHeight;
toggleCollapseNav({target: sortedItems[i].children[0]}, true);
sortedItems.splice(i, 1);
break;
}
}
}
}
/*
Initialize the interactive functionality of the page.
*/
function init() {
2016-01-12 04:29:11 +00:00
var i, j;
2015-12-26 04:09:32 +00:00
// Make collapse buttons clickable
var buttons = document.querySelectorAll('.collapse-button');
for (i = 0; i < buttons.length ; i + + ) {
buttons[i].onclick = toggleCollapseButton;
// Show by default? Then toggle now.
if (buttons[i].className.indexOf('show') !== -1) {
toggleCollapseButton({target: buttons[i].children[0]});
}
}
2016-01-12 04:29:11 +00:00
var responseCodes = document.querySelectorAll('.example-names');
for (i = 0; i < responseCodes.length ; i + + ) {
var tabButtons = childrenByClass(responseCodes[i], 'tab-button');
for (j = 0; j < tabButtons.length ; j + + ) {
tabButtons[j].onclick = toggleTabButton;
// Show by default?
if (j === 0) {
toggleTabButton({target: tabButtons[j]});
}
}
}
2015-12-26 04:09:32 +00:00
// Make nav items clickable to collapse/expand their content.
var navItems = document.querySelectorAll('nav .resource-group .heading');
for (i = 0; i < navItems.length ; i + + ) {
navItems[i].onclick = toggleCollapseNav;
// Show all by default
toggleCollapseNav({target: navItems[i].children[0]});
}
}
// Initial call to set up buttons
init();
window.onload = function () {
autoCollapse();
// Remove the `preload` class to enable animations
document.querySelector('body').className = '';
};
< / script > < / body > < / html >
2015-12-27 02:48:10 +00:00
{{ end }}