WC_API_JSON_Handler::parse_body()publicWC 2.1

Parse the raw request body entity

Method of the class: WC_API_JSON_Handler{}

No Hooks.

Return

Array|Mixed.

Usage

$WC_API_JSON_Handler = new WC_API_JSON_Handler();
$WC_API_JSON_Handler->parse_body( $body );
$body(string) (required)
the raw request body

Changelog

Since 2.1 Introduced.

WC_API_JSON_Handler::parse_body() code WC 8.6.1

public function parse_body( $body ) {

	return json_decode( $body, true );
}