LucasSch2410's avatar

How send base64 image to front-end?

Hello!

I'm using Amplify + Aws Rekognition + FaceLiveness and i have a problem in this method:

GetFaceLivenessSessionResults

Using the Amplify front+backend, i can just get the data correctly, but i'm using a back-end in Laravel and just using the components for Liveness Service in front-end.

This code below is my code to get the results of the LivenessSession, and when i send it to front-end, i have this error in ReferenceImage/Bytes key:

Malformed UTF-8 characters, possibly incorrectly encoded

This is the type of the key:

Bytes The Base64-encoded bytes representing an image selected from the Face Liveness video and returned for audit purposes.

Type: Base64-encoded binary data object

Length Constraints: Minimum length of 1. Maximum length of 204800.

Required: No

And i already used base64_encode, decode, utf8 encode and decode and don't can just send the image to the front-end, i really will be grateful if anyone help me! :)

0 likes
0 replies

Please or to participate in this conversation.