Difference between revisions of "Rackspace Storage Notification (Rest API)"

From Rackspace Email & Apps API
Jump to: navigation, search
(Created page with '__TOC__ == Show == ''URL'': <nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name) /rs/storageNotification)</nowiki> ''…')
 
(remove accept header from examples to avoid confusion)
 
(5 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
__TOC__
 
__TOC__
  
== Show ==
+
== v1 - Current ==
 +
 
 +
=== Show ===
  
 
''URL'':
 
''URL'':
  <nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)/rs/storageNotification</nowiki>
        /rs/storageNotification)</nowiki>
 
  
  
Line 15: Line 16:
 
''Remarks'':
 
''Remarks'':
  
The show operation only supports the GET HTTP verb. For .xml format refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/RSMailbox.xsd RSMailbox.xsd]
+
The show operation only supports the GET HTTP verb.
  
  
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
get '/customers/12345678/domains/example.com/rs/storageNotification', 'text/xml'
+
get '/customers/12345678/domains/example.com/rs/storageNotification'
 
</pre>
 
</pre>
  
Line 39: Line 40:
 
</pre>
 
</pre>
  
== Edit ==
+
=== Edit ===
  
 
''URL'':
 
''URL'':
Edit: [PUT] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
<nowiki>[PUT] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)/rs/storageNotification</nowiki>
        /rs/storageNotification</nowiki>
 
  
 
''Description'':
 
''Description'':
Line 56: Line 56:
 
| enabled
 
| enabled
 
| boolean
 
| boolean
| Activates domain storage notification. (Required for Add)
+
| Activates domain storage notification. (Required)
 
|-
 
|-
 
| notificationPercentage
 
| notificationPercentage
Line 73: Line 73:
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
post '/customers/12345678/domains/example.com/rs/mailboxes/alex.smith', 'text/xml',
+
post '/customers/12345678/domains/example.com/rs/mailboxes/alex.smith',
 
{  
 
{  
 
   'enabled' => 'true',
 
   'enabled' => 'true',

Latest revision as of 13:45, 12 January 2017

v1 - Current

Show

URL:

[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)/rs/storageNotification


Description:

The show operation will return detailed information about a given domain's Rackspace Mailbox storage notification settings that control whether an email notification is sent to users when their mailbox reaches a certain capacity.


Remarks:

The show operation only supports the GET HTTP verb.


Example:

get '/customers/12345678/domains/example.com/rs/storageNotification'


XML Result Example:

<rsStorageNotification xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:rsStorageNotification">
  <enabled>true</enabled>
  <notificationCC>test@email.net</notificationCC>
  <notificationMessage>The mailbox is getting full.</notificationMessage>
  <notificationPercentage>99</notificationPercentage>
</rsStorageNotification>

Json Result Example:

{"enabled":true, "notificationCC":"test@email.net", "notificationMessage":"Test", "notificationPercentage":99}

Edit

URL:

[PUT] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)/rs/storageNotification

Description:

The edit operation will set detailed information about a given domain's Rackspace Mailbox storage notification settings.

Field Name Data Type Description
enabled boolean Activates domain storage notification. (Required)
notificationPercentage int The storage percentage that triggers the notification. (Required for Add) (Valid Values: 50, 60, 70, 80, 90, 99)
notificationMessage string The notification message. (The special tag <*USER*> will substitute in the username. The special tag <*DOMAIN*> will substitute in the domain.)
notificationCC string An email address the notification message will be carbon copied to.

Example:

post '/customers/12345678/domains/example.com/rs/mailboxes/alex.smith',
{ 
  'enabled' => 'true',
  'notificationPercentage' => '90',
  'notificationMessage' => 'Your mailbox "<*USER*>@<*DOMAIN*>" is almost full.',
  'notificationCC' => 'test@testdomain.com'
}