clarifai-nodejs-grpc
clarifai-nodejs-grpc copied to clipboard
Metadata does not upload
Using a similar call:
// This will be used by every Clarifai endpoint call.
const metadata = new grpc.Metadata()
metadata.set('authorization', 'Key XXXXX')
stub.PostInputs(
{
inputs: [{data: {
image: {url: "https://samples.clarifai.com/puppy.jpeg", allow_duplicate_url: true},
metadata: {id: "id001", type: "animal", size: 100}
}}]
},
metadata,
(err, response) => {
if (err) {
throw new Error(err);
}
if (response.status.code !== 10000) {
throw new Error("Post inputs failed, status: " + response.status.description);
}
}
);
Metadata is not attached to the input when you check via the Portal or any other method. This seems to happen only with this gRPC client.