Updated on 2024-08-16 GMT+08:00

Starting and Logging In to the App

Description

If the Huawei Cloud Meeting client is installed on a user device, the user can start and log in to the client in this mode. The home screen is displayed after login.

1. If the user has not logged in when clicking the link, the user will log in to the client using the account used to obtain the token and the home screen is displayed.

2. If the user has logged in, the home screen is displayed. Login is not performed again.

Service Process

  1. Perform app ID authentication. For details, see Authenticating an App ID in API Reference.
  2. Obtain a nonce. For details, see Obtaining a Nonce for Redirection Without Login in API Reference.
  3. Start the Huawei Cloud Meeting client and log in to the home screen. For details, see the following sample code.

Code Sample

- (void)handleEventWithNonce:(NSString *)nonce {
    NSString * schemeStr = [NSString stringWithFormat:@"cloudlink://welinksoftclient/h5page?page=launch&nonce=%@", nonce];
    NSLog(@"schemeStr:%@", schemeStr);
    NSURL *schemUrl = [[NSURL alloc] initWithString:[schemeStr stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet URLQueryAllowedCharacterSet]]];
    [[NSWorkspace sharedWorkspace] openURL:schemUrl];
}

The preceding code is only a logical sample and cannot be directly used.