list_channels
async
¶
list_channels(
app_instance_arn: ChimeArn,
chime_bearer: ChimeArn,
*,
config_overrides: Optional[AsyncChimeSDKMessagingClientConfig] = None,
privacy: Optional[ChannelPrivacy] = None,
max_results: Optional[MaxResults] = None,
next_token: Optional[NextToken] = None,
) -> ListChannelsResponse
Lists all Channels created under a single Chime App as a paginated list. You can specify filters to narrow results.
Functionality & restrictions
-
Use privacy =
PUBLICto retrieve all public channels in the account. -
Only an
AppInstanceAdmincan set privacy =PRIVATEto list the private channels in an account.
The x-amz-chime-bearer request header is mandatory. Use the ARN of the AppInstanceUser or AppInstanceBot that makes the API call as the value in the header.
Parameters:
-
app_instance_arn(ChimeArn) –The ARN of the
AppInstance. -
privacy(Optional[ChannelPrivacy], default:None) –The privacy setting.
PUBLICretrieves all the public channels.PRIVATEretrieves private channels. Only anAppInstanceAdmincan retrieve private channels. -
max_results(Optional[MaxResults], default:None) –The maximum number of channels that you want to return.
-
next_token(Optional[NextToken], default:None) –The token passed by previous API calls until all requested channels are returned.
-
chime_bearer(ChimeArn) –The ARN of the
AppInstanceUserorAppInstanceBotthat makes the API call.
Raises:
-
BadRequestException–The input parameters don't match the service's restrictions.
-
ForbiddenException–The client is permanently forbidden from making the request.
-
ServiceFailureException–The service encountered an unexpected error.
-
ServiceUnavailableException–The service is currently unavailable.
-
ThrottledClientException–The client exceeded its request rate limit.
-
UnauthorizedClientException–The client is not currently authorized to make the request.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_chime_sdk_messaging/_services/async_chime_sdk_messaging.py
2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 | |