WordPress at a glance
function is not described

wc_rest_check_post_permissions() WC 2.6.0

Check permissions of posts on REST API.

Hooks from the function
Return

true|false. Nothing.

Usage

wc_rest_check_post_permissions( $post_type, $context, $object_id );
$post_type(string) (required)
Post type.
$context(string)
Request context.
$object_id(int)
Post ID.

Changelog

Since 2.6.0 Introduced.

Code of wc_rest_check_post_permissions() WC 5.3.0

<?php
function wc_rest_check_post_permissions( $post_type, $context = 'read', $object_id = 0 ) {
	$contexts = array(
		'read'   => 'read_private_posts',
		'create' => 'publish_posts',
		'edit'   => 'edit_post',
		'delete' => 'delete_post',
		'batch'  => 'edit_others_posts',
	);

	if ( 'revision' === $post_type ) {
		$permission = false;
	} else {
		$cap              = $contexts[ $context ];
		$post_type_object = get_post_type_object( $post_type );
		$permission       = current_user_can( $post_type_object->cap->$cap, $object_id );
	}

	return apply_filters( 'woocommerce_rest_check_permissions', $permission, $context, $object_id, $post_type );
}