ocs_rml_awss3_bucket_host

Since version 1.10.5, this filter generates the root url of the bucket items. It runs only once when extracting a list of buckets items.

function ocs_rml_s3_bucket_host( $bucket_host, $bucket_name, $library_post_id ) {
        //Do something here

        return $bucket_host;
}
add_filter( 'ocs_rml_awss3_bucket_host', 'ocs_rml_s3_bucket_host', 10, 3);

ocs_rml_awss3_object_url

Since version 1.10.5, this filter runs to generate bucket objects URL. Be careful not to run anything heavy, or use some cache method, as this runs for every items in your bucket and can have a significant performance impact when scrolling through your bucket items of the media library.

function ocs_rml_s3_object_url( $object_url, $object_host, $object_path, $library_post_id ) {
        //Do something here

        return $object_url;
}
add_filter( 'ocs_rml_awss3_object_url', 'ocs_rml_s3_object_url', 10, 4);