TIMGroupGetPendencyList

Introduction

Get group pendency list

Group pendency contains all group related operations that requires certain permissions. Eg. group joining pendency, group invitation and so on. Even if it is handled (granted/rejected), the pendency can be retrieved by this API and it has handled flag.

UserA applied to groupA, the group owner or admin get retrieve this pendency, because it is determined by the group owner or admin.

If adminA invited userA to groupA, userA can retrieve the pendency because it is determined by userA.

Permission description

Only pendency handlers can retrieve unresolved pendency.

Set group_pendency_option_start_time for start time, input 0 at first and fill out later by returned group_pendency_result_next_start_time in GroupPendencyResult.

Use group_pendency_option_max_limited to set maximum number of pendencies, the server may return less number than this and don't use this as finished flag.

Parameter details

Parameter name Parameter type Required Description
getPendencyListParams GetPendencyListParams yes Param of getting group pendency list

Returned template

Promise<commonResult<GroupPendencyResult>>

{
    code: TIMResult | TIMErrCode;
    desc?: string | undefined;
    json_param?: GroupPendencyResult | undefined;
    json_params?: GroupPendencyResult | undefined; 
    user_data?: string | undefined;
}

Return value details

name type description
code TIMResultTIMErrCode Request result: Error codes. 0 means success.
desc string | undefined The description of the error. It will be empty if success.
json_param GroupPendencyResult | undefined Return value of calling API
json_params GroupPendencyResult | undefined Return value of calling API. Compatible field, which is returned in some cases.
user_data string | undefined ImSDK is responsible for transporting user-defined data without any processing

Code example

import TimRender from "im_electron_sdk/dist/renderer";
const timRenderInstance = new TimRender();
import { GetPendencyListParams } from "im_electron_sdk/dist/interfaces";

let param: GetPendencyListParams = {
  params: {
    group_pendency_option_start_time: 0,  // required
    group_pendency_option_max_limited: 0, // required
  },
  data: 'test data'   // optional
}
const { code } = await timRenderInstance.TIMGroupGetPendencyList(param)

if (code == 0) {
  // success
}

results matching ""

    No results matching ""