简体   繁体   中英

Receiving SMS in C# with RingCentral

I am able to send SMS using C#. But my problem is I don't know to receive those SMS.

I looked into following documentation with WebHook and C# here:

https://developers.ringcentral.com/guide/notifications/quick-start/webhook/c-sharp

But not sure how to do it exactly.

Can I get any help to know how I can receive the SMS. Any sample will be great.

There are 3 ways to receive SMS:

  • PubNub Subscription
  • WebHook Subscription
  • API Request

Here are some details:

  1. Using PubNub , you can receive SMS.
    Check it out here: https://github.com/ringcentral/ringcentral-csharp-client/blob/master/RingCentral.Test/SubscripotionTest.cs#L31
    Since this is used by PubNub , so you don't need ngrok

  2. If you want WebHook , you need to subscribe for push notification check the reference demo: https://github.com/ringcentral/ringcentral-csharp-client/blob/master/RingCentral.Test/WebHookTest.cs

  3. The direct API of RingCentral APIs to receive SMS content in your C# , by calling this API inside your SDK is: /restapi/v1.0/account/~/extension/~/message-store/{messageId}/content/{attachmentId} . Here you need to put the message id and the attachment id to retrieve message content from message-store

Hope this help.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM