SMSSDK.h 3.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. //
  2. // SMS_SDK.h
  3. // SMS_SDKDemo
  4. //
  5. // Created by 刘 靖煌 on 14-8-28.
  6. // Copyright (c) 2014年 掌淘科技. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. #import <SMS_SDK/Extend/SMSSDKResultHanderDef.h>
  10. #import <SMS_SDK/Extend/SMSSDKUserInfo.h>
  11. /**
  12. * @brief 核心类(Core class)v2.1.5
  13. */
  14. @interface SMSSDK : NSObject
  15. /**
  16. *
  17. ***** 请注意:测试短信条数限制发送数量:20条/天,APP开发完成后请到Mob官网(http://mob.com/ )后台提交审核,获得不限制条数的免费短信权限。
  18. *
  19. * 初始化应用,此方法在应用启动时在主线程中调用。(This method is called in the main thread in application:didFinishLaunchingWithOptions: method)
  20. *
  21. * @param appKey 在Mob官网(http://mob.com/ )中注册的应用Key。(The appKey of mob Application. Log in to http://mob.com/ to register to be a Mob developer and create a application if you don't have one)
  22. * @param appSecret 在Mob官网(http://mob.com/ )中注册的应用秘钥。(The appSecret of mob Application. Log in to http://mob.com/ to register to be a Mob developer and create a application if you don't have one)
  23. */
  24. + (void) registerApp:(NSString*)appKey withSecret:(NSString*)appSecret;
  25. #pragma mark - 支持获取验证码和提交验证码 (get the verification code and commit verifacation code)
  26. /**
  27. * @from v1.1.1
  28. * @brief 获取验证码(Get verification code)
  29. *
  30. * @param method 获取验证码的方法(The method of getting verificationCode)
  31. * @param phoneNumber 电话号码(The phone number)
  32. * @param zone 区域号,不要加"+"号(Area code)
  33. * @param customIdentifier 自定义短信模板标识 该标识需从官网http://www.mob.com上申请,审核通过后获得。(Custom model of SMS. The identifier can get it from http://www.mob.com when the application had approved)
  34. * @param result 请求结果回调(Results of the request)
  35. */
  36. + (void) getVerificationCodeByMethod:(SMSGetCodeMethod)method
  37. phoneNumber:(NSString *)phoneNumber
  38. zone:(NSString *)zone
  39. customIdentifier:(NSString *)customIdentifier
  40. result:(SMSGetCodeResultHandler)result;
  41. /**
  42. * @from v1.1.1
  43. * @brief 提交验证码(Commit the verification code)
  44. *
  45. * @param code 验证码(Verification code)
  46. * @param phoneNumber 电话号码(The phone number)
  47. * @param zone 区域号,不要加"+"号(Area code)
  48. * @param result 请求结果回调(Results of the request)
  49. */
  50. + (void) commitVerificationCode:(NSString *)code
  51. phoneNumber:(NSString *)phoneNumber
  52. zone:(NSString *)zone
  53. result:(SMSCommitCodeResultHandler)result;
  54. /**
  55. * @from v2.0.1
  56. * @return 返回SDK版本号(Return the version number of this SDK)
  57. */
  58. + (NSString *) SMSSDKVersion;
  59. @end