Skip to content

Releases: department-of-veterans-affairs/notifications-java-client

2.0.0

04 Feb 17:35
f5d9a6c
Compare
Choose a tag to compare

Changes in 2.0.0

  • Added GSON library as dependency
  • Refactored all JSON serialization and deserialization to use GSON

Breaking changes

  • Removed deprecated sendEmail and sendSms methods.

    You have to use new EmailRequest.Builder() and new SmsRequest.Builder() to fluently construct your requests starting with version 2.

Download binary from GH Package Maven Repository

https://github.com/department-of-veterans-affairs/notifications-java-client/packages/990487?version=2.0.0

1.2.0

30 Sep 03:02
Compare
Choose a tag to compare

Changes in 1.2.0

  • Added support for sending notification requests with recipient identifiers supported by Master Person Index.
    Identifiers will be used to lookup contact information (email, phone number) as well as contact preferences in VA Profile.

    Currently supported identifiers include:

    • ICN
    • VA Profile Id
    • Participant Id
    • Birls Id (FileNumber)
    • EDIPI

You can send requests that contain only recipient identifier, for example:

SendEmailResponse response = client.sendEmail(new EmailRequest.Builder()
        .withTemplateId("aTemplateId")
        .withRecipientIdentifier(new Identifier(IdentifierType.VAPROFILEID, "some-id");
        .build()
      );

Or you can specify both email / phone number and identifier. In that case identifier will be only used to lookup preferences.

SendEmailResponse response = client.sendEmail(new EmailRequest.Builder()
        .withTemplateId("aTemplateId")
        .withEmailAddress("[email protected]")
        .withRecipientIdentifier(new Identifier(IdentifierType.VAPROFILEID, "some-id");
        .build()
      );
  • Moved all tests to Junit5.

Download binary from GH Package Maven Repository

https://github.com/department-of-veterans-affairs/notifications-java-client/packages/990487?version=1.2.0

1.1.0

20 Sep 20:52
Compare
Choose a tag to compare

Changes in 1.1.0

  • Added EmailRequest with a fluent builder to avoid constructors with lots of same type optional arguments.
    You can use it as follows:
    SendEmailResponse response = client.sendEmail(new EmailRequest.Builder()
                  .withTemplateId("aTemplateId")
                  .withEmailAddress("[email protected]")
                  .withPersonalisation(emptyMap())
                  .withReference("aReference")
                  .withBillingCode("aBillingCode")
                  .withEmailReplyToId("aEmailReplyToId")
                  .build()
          );
    
  • Deprecated following NotificationClientApi sendEmail methods:
    @Deprecated
    SendEmailResponse sendEmail(String templateId, String emailAddress, Map<String, ?> personalisation, String reference, String billingCode) throws NotificationClientException;
    
    @Deprecated
    SendEmailResponse sendEmail(String templateId, String emailAddress, Map<String, ?> personalisation, String reference, String billingCode, String emailReplyToId) throws NotificationClientException;
    
  • Added SmsRequest with a fluent builder to avoid constructors with lots of same type optional arguments.
    You can use it as follows:
    client.sendSms(new SmsRequest.Builder()
                  .withTemplateId("aTemplateId")
                  .withPhoneNumber("aPhoneNumber")
                  .withPersonalisation(emptyMap())
                  .withReference("aReference")
                  .withBillingCode("aBillingCode")
                  .withSmsSenderId("aSmsSenderId")
                  .build()
          );
    
  • Deprecated following NotificationClientApi sendSms methods:
    @Deprecated
    SendSmsResponse sendSms(String templateId, String phoneNumber, Map<String, ?> personalisation, String reference, String billingCode) throws NotificationClientException;
    
    @Deprecated
    SendSmsResponse sendSms(String templateId, String phoneNumber, Map<String, ?> personalisation, String reference, String billingCode, String smsSenderId) throws NotificationClientException;
    

Download binary from GH Package Maven Repository

https://github.com/department-of-veterans-affairs/notifications-java-client/packages/990487?version=1.1.0