DOCUMENTATION.md in notifications-ruby-client-3.0.0 vs DOCUMENTATION.md in notifications-ruby-client-3.1.0

- old
+ new

@@ -443,36 +443,37 @@ ## Status - text and email |Status|Information| |:---|:---| -|Created|The message is queued to be sent to the provider. The notification usually remains in this state for a few seconds.| -|Sending|The message is queued to be sent by the provider to the recipient, and GOV.UK Notify is waiting for delivery information.| +|Created|GOV.UK Notify has placed the message in a queue, ready to be sent to the provider. It should only remain in this state for a few seconds.| +|Sending|GOV.UK Notify has sent the message to the provider. The provider will try to deliver the message to the recipient. GOV.UK Notify is waiting for delivery information.| |Delivered|The message was successfully delivered.| -|Failed|This covers all failure statuses:<br>- `permanent-failure` - "The provider was unable to deliver message, email or phone number does not exist; remove this recipient from your list"<br>- `temporary-failure` - "The provider was unable to deliver message, email inbox was full or phone was turned off; you can try to send the message again"<br>- `technical-failure` - "Notify had a technical failure; you can try to send the message again"| +|Failed|This covers all failure statuses:<br>- `permanent-failure` - "The provider could not deliver the message because the email address or phone number was wrong. You should remove these email addresses or phone numbers from your database. You’ll still be charged for text messages to numbers that do not exist."<br>- `temporary-failure` - "The provider could not deliver the message after trying for 72 hours. This can happen when the recipient's inbox is full or their phone is off. You can try to send the message again. You’ll still be charged for text messages to phones that are not accepting messages."<br>- `technical-failure` - "Your message was not sent because there was a problem between Notify and the provider.<br>You’ll have to try sending your messages again. You will not be charged for text messages that are affected by a technical failure."| ## Status - text only |Status|Information| |:---|:---| -|Pending|GOV.UK Notify received a callback from the provider but the device has not yet responded. Another callback from the provider determines the final status of the notification.| -|Sent|The text message was delivered internationally. This only applies to text messages sent to non-UK phone numbers. GOV.UK Notify may not receive additional status updates depending on the recipient's country and telecoms provider.| +|Pending|GOV.UK Notify is waiting for more delivery information.<br>GOV.UK Notify received a callback from the provider but the recipient's device has not yet responded. Another callback from the provider determines the final status of the notification.| +|Sent / Sent internationally|The message was sent to an international number. The mobile networks in some countries do not provide any more delivery information. The GOV.UK Notify client API returns this status as `sent`. The GOV.UK Notify client app returns this status as `Sent internationally`.| ## Status - letter |Status|information| |:---|:---| |Failed|The only failure status that applies to letters is `technical-failure`. GOV.UK Notify had an unexpected error while sending to our printing provider.| -|Accepted|GOV.UK Notify is printing and posting the letter.| -|Received|The provider has received the letter to deliver.| +|Accepted|GOV.UK Notify has sent the letter to the provider to be printed.| +|Received|The provider has printed and dispatched the letter.| ## Status - precompiled letter |Status|information| |:---|:---| -|Pending virus check|GOV.UK Notify virus scan of the precompiled letter file is not yet complete.| -|Virus scan failed|GOV.UK Notify virus scan has identified a potential virus in the precompiled letter file.| +|Pending virus check|GOV.UK Notify has not completed a virus scan of the precompiled letter file.| +|Virus scan failed|GOV.UK Notify found a potential virus in the precompiled letter file.| +|Validation failed|Content in the precompiled letter file is outside the printable area.| ## Get the status of one message You can only get the status of messages that are 7 days old or newer. @@ -562,23 +563,26 @@ You can leave out these arguments to ignore these filters. #### status (optional) -| status | description | text | email | letter | -|:--- |:--- |:--- |:--- |:--- | -|`created` |The message is queued to be sent to the provider|Yes|Yes|| -|`sending` |The message is queued to be sent by the provider to the recipient|Yes|Yes|| -|`delivered`|The message was successfully delivered|Yes|Yes|| -|`pending`|GOV.UK Notify received a callback from the provider but the device has not yet responded|Yes||| -|`sent`|The text message was delivered internationally|Yes|Yes|| -|`failed`|This returns all failure statuses:<br>- `permanent-failure`<br>- `temporary-failure`<br>- `technical-failure`|Yes|Yes|| -|`permanent-failure`|The provider was unable to deliver message, email or phone number does not exist; remove this recipient from your list|Yes|Yes|| -|`temporary-failure`|The provider was unable to deliver message, email inbox was full or phone was turned off; you can try to send the message again|Yes|Yes|| -|`technical-failure`|Email / Text: Notify had a technical failure; you can try to send the message again. <br><br>Letter: Notify had an unexpected error while sending to our printing provider. <br><br>You can leave out this argument to ignore this filter.|Yes|Yes|| -|`accepted`|Notify is printing and posting the letter|||Yes| -|`received`|The provider has received the letter to deliver|||Yes| +| status | description | text | email | letter |Precompiled letter| +|:--- |:--- |:--- |:--- |:--- |:--- | +|created|GOV.UK Notify has placed the message in a queue, ready to be sent to the provider. It should only remain in this state for a few seconds.|Yes|Yes||| +|sending|GOV.UK Notify has sent the message to the provider. The provider will try to deliver the message to the recipient. GOV.UK Notify is waiting for delivery information.|Yes|Yes||| +|delivered|The message was successfully delivered|Yes|Yes||| +|sent / sent internationally|The message was sent to an international number. The mobile networks in some countries do not provide any more delivery information.|Yes|||| +|pending|GOV.UK Notify is waiting for more delivery information.<br>GOV.UK Notify received a callback from the provider but the recipient's device has not yet responded. Another callback from the provider determines the final status of the notification.|Yes|||| +|failed|This returns all failure statuses:<br>- permanent-failure<br>- temporary-failure<br>- technical-failure|Yes|Yes||| +|permanent-failure|The provider could not deliver the message because the email address or phone number was wrong. You should remove these email addresses or phone numbers from your database. You’ll still be charged for text messages to numbers that do not exist.|Yes|Yes||| +|temporary-failure|The provider could not deliver the message after trying for 72 hours. This can happen when the recipient's inbox is full or their phone is off. You can try to send the message again. You’ll still be charged for text messages to phones that are not accepting messages.|Yes|Yes||| +|technical-failure|Email / Text: Your message was not sent because there was a problem between Notify and the provider.<br>You’ll have to try sending your messages again. You will not be charged for text messages that are affected by a technical failure. <br><br>Letter: Notify had an unexpected error while sending to our printing provider. <br><br>You can leave out this argument to ignore this filter.|Yes|Yes||| +|accepted|GOV.UK Notify has sent the letter to the provider to be printed.|||Yes|| +|received|The provider has printed and dispatched the letter.|||Yes|| +|pending-virus-check|GOV.UK Notify is scanning the precompiled letter file for viruses.||||Yes| +|virus-scan-failed|GOV.UK Notify found a potential virus in the precompiled letter file.||||Yes| +|validation-failed|Content in the precompiled letter file is outside the printable area.||||Yes| #### templateType (optional) You can filter by: @@ -856,9 +860,10 @@ |`response.id`|Template UUID|String| |`response.version`|Template version|String| |`response.body`|Template content|String| |`response.subject`|Template subject (email and letter)|String| |`response.type`|Template type (sms/email/letter)|String| +|`response.html`|Body as rendered HTML (email only)|String| ### Error codes If the request is not successful, the client returns a `Notifications::Client::RequestError` and an error code: