Sorry for the delay. Please try this code snippet, it should add the offers property to the listing Schema:
add_filter(
'hivepress/v1/models/listing/schema',
function( $schema ) {
$listing = hivepress()->request->get_context( 'listing' );
if ( ! $listing ) {
return $schema;
}
$schema['offers'] = [
'@type' => 'Offer',
'availability' => 'https://schema.org/InStock',
'price' => $listing->get_price(),
'priceCurrency' => 'USD',
];
return $schema;
}
);
Replace “price” in “get_price” if the attribute field name is different.