Agora RTC Objective-C API Reference Refactor

Instance Methods | Properties
AgoraRtmClientConfig Class Reference

Inherits <NSObject>.

## Instance Methods
(instancetype _Nonnull) | - initWithAppId:userId:

## Properties
AgoraRtmAreaCode | areaCode
AgoraRtmProtocolType | protocolType
unsigned int | presenceTimeout
unsigned int | heartbeatInterval
NSString * | appId
NSString * | userId
BOOL | useStringUserId
BOOL | multipath
BOOL | ispPolicyEnabled
AgoraRtmLogConfig * | logConfig
AgoraRtmProxyConfig * | proxyConfig
AgoraRtmEncryptionConfig * | encryptionConfig
AgoraRtmPrivateConfig * | privateConfig

## Detailed Description

Configurations for RTM Client.

## Method Documentation

## ◆ NS_UNAVAILABLE

- (instancetype _Nullable) NS_UNAVAILABLE |  |  |

## ◆ initWithAppId:userId:

- (instancetype _Nonnull) initWithAppId: |  | (NSString *_Nonnull) | appId
userId: |  | (NSString *_Nonnull) | userId

init with appid adn userid

## Property Documentation

## ◆ areaCode

- (AgoraRtmAreaCode) areaCode
| read write nonatomic assign

The region for connection. This advanced feature applies to scenarios that have regional restrictions.

For the regions that Agora supports, see #AREA_CODE.

After specifying the region, the SDK connects to the Agora servers within that region.

## ◆ protocolType

- (AgoraRtmProtocolType) protocolType
| read write nonatomic assign

The protocol used for connecting to the Agora RTM service.

## ◆ presenceTimeout

- (unsigned int) presenceTimeout
| read write nonatomic assign

Presence timeout in seconds, specify the timeout value when you lost connection between sdk and rtm service.

## ◆ heartbeatInterval

- (unsigned int) heartbeatInterval
| read write nonatomic assign

Heartbeat interval in seconds, specify the interval value of sending heartbeat between sdk and rtm service.

## ◆ appId

- (NSString*) appId
| read write nonatomic copy

The App ID of your project.

## ◆ userId

- (NSString*) userId
| read write nonatomic copy

The ID of the user.

## ◆ useStringUserId

- (BOOL) useStringUserId
| read write nonatomic assign

Whether to use String user IDs, if you are using RTC products with Int user IDs, set this value as 'false'. Otherwise errors might occur.

## ◆ multipath

- (BOOL) multipath
| read write nonatomic assign

Whether to enable multipath, introduced from 2.2.0, for now , only effect on stream channel.

## ◆ ispPolicyEnabled

- (BOOL) ispPolicyEnabled
| read write nonatomic assign

iot devices may be restricted by isp, need to enable this feature to connect to server by domain. -true: connect to servers restricted by isp -false: (Default) connect to servers with no limit

## ◆ logConfig

- (AgoraRtmLogConfig*) logConfig
| read write nonatomic copy

The config for customer set log path, log size and log level.

## ◆ proxyConfig

- (AgoraRtmProxyConfig*) proxyConfig
| read write nonatomic copy

The config for proxy setting

## ◆ encryptionConfig

- (AgoraRtmEncryptionConfig*) encryptionConfig
| read write nonatomic copy

The config for encryption setting

## ◆ privateConfig

- (AgoraRtmPrivateConfig*) privateConfig
| read write nonatomic copy

The config for private setting