I write this article not because Ali cloud messaging study documents provided good service, but the use of documentation it provides for me this rookie first-time friendship is not enough, there are still many pits document does not say so. Record your own way bit by bit.
1. Using the steps Ali cloud interface
First, we log in aliyun official website
after the successful landing
and then locate the SMS service
screen after entering that
I am here, "management console" because I have opened for the first time when the opening should first open the service to the console management .
When the SMS service after you open the service console,
you must first apply for signature
and then you fill in some information after the application you have to wait about two hours to get signatures
second application is the template that you want users to send SMS templates
that have pending review about two hours. . . .
When you apply all finished, the next step is to call the short message interface code to put your java code.
Now we find sample code
to decline after the jump to find
we can first call to see what
your code that uses it sent successfully, would like to achieve is to ctrl + C in your code, ctrl + V the
use Maven then introduced to jar package will be much simpler, there is the code
DefaultProfile profile = DefaultProfile.getProfile("default", "<accessKeyId>", "<accessSecret>");
Into your accessKeyId, accessSecret
show you