This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| message = client.sms.messages.create( | |
| to="+12316851234", | |
| from_="+15555555555", | |
| body="Hello there!" | |
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #import <UIKit/UIKit.h> | |
| #import "WXApi.h" | |
| // Add the WXApiDelegate protocol | |
| @interface AppDelegate : UIResponder <UIApplicationDelegate, WXApiDelegate> | |
| @property (strong, nonatomic) UIWindow *window; | |
| @end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // To share text messages, you only need the below | |
| SendMessageToWXReq *req = [[[SendMessageToWXReq alloc] init] autorelease]; | |
| req.text = @"Your Text Message."; | |
| req.bText = YES; | |
| // Uncomment the 1st line to share to WeChat contacts, or the 2nd line to share to WeChat Moments | |
| // req.scene = WXSceneSession; | |
| // req.scene = WXSceneTimeline; | |
| [WXApi sendReq:req]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Start by instantiating the message | |
| WXMediaMessage *message = [WXMediaMessage message]; | |
| // Set (optional) title, description, and thumbnail | |
| message.title = @"News Article Title"; | |
| message.description = @"Article Description"; | |
| [message setThumbImage:[UIImage imageNamed:@"res1thumb.png"]]; | |
| // Create the webpage object and attach it to the message | |
| WXWebpageObject *ext = [WXWebpageObject object]; | |
| ext.webpageUrl = @"http://www.engadget.com/2013/06/22/acer-aspire-p3-review/"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Start by instantiating the message | |
| WXMediaMessage *message = [WXMediaMessage message]; | |
| // Set (optional) title, description, and thumbnail | |
| message.title = @"Video Title"; | |
| message.description = @"Amazing Video"; | |
| [message setThumbImage:[UIImage imageNamed:@"res2.jpg"]]; | |
| // Create the video object and attach it to the message | |
| WXVideoObject *ext = [WXVideoObject object]; | |
| ext.videoUrl = @"http://www.youtube.com/watch?v=UF8uR6Z6KLc"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Start by instantiating the message | |
| WXMediaMessage *message = [WXMediaMessage message]; | |
| // Set (optional) title, description, and thumbnail | |
| message.title = @"Song Title"; | |
| message.description = @"Amazing Song"; | |
| [message setThumbImage:[UIImage imageNamed:@"res1thumb.png"]]; | |
| // Create the music object and attach it to the message | |
| WXMusicObject *ext = [WXMusicObject object]; | |
| NSString *filePath = [[NSBundle mainBundle] pathForResource:@"res1" ofType:@"jpg"]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!-- Open Graph data --> | |
| <meta property="og:title" content="Title Here" /> | |
| <meta property="og:type" content="article" /> | |
| <meta property="og:url" content="http://www.example.com/" /> | |
| <meta property="og:image" content="http://example.com/image.jpg" /> | |
| <meta property="og:description" content="Description Here" /> | |
| <meta property="og:site_name" content="Site Name, i.e. Moz" /> | |
| <meta property="og:price:amount" content="15.00" /> | |
| <meta property="og:price:currency" content="USD" /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Start by instantiating the message | |
| WXMediaMessage *message = [WXMediaMessage message]; | |
| // Set (optional) title, description, and thumbnail | |
| message.title = @"Some Title"; | |
| message.description = @"Amazing Sunset"; | |
| [message setThumbImage:[UIImage imageNamed:@"res1thumb.png"]]; | |
| // Create the image object and attach it to the message | |
| WXImageObject *ext = [WXImageObject object]; | |
| NSString *filePath = [[NSBundle mainBundle] pathForResource:@"res1" ofType:@"jpg"]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {{#with dataObj }} | |
| {{> templateName }} | |
| {{/with}} |