Upload AI/ML Model to LEM
3 min
upload ai/ml model to lem ui trigger lem > edge lifecycle management > ai/ml models > upload new model lem uses a pre signed s3 url pattern instead of the le resumable session pattern step 1 gets a signed url; step 2 uploads directly to object storage; step 3 registers the model in lem step table step name in collection method endpoint body / notes output 1 step 1 of upload new ai/ml model post {{lem url}}/api/v1/file/{{project id}}/mlmodel/{{filename}}/upload url {"projectid" " ", "filename" "model zip"} {"url" "\<signed s3 url>"} 2 step 2 of upload new ai/ml model put \<signed s3 url from step 1> binary zip model file bytes url carries aws sigv4 query params 200 ok (s3 direct upload) 3 step 3 of upload new model post {{lem url}}/api/v1/file/{{project id}}/mlmodel/{{filename}} {"description" " "} registers the model in lem model available in lem auth notes steps 1 and 3 use x authtoken {{lem adminapitoken}} step 2 (s3 put) uses the embedded aws sigv4 signature in the url no additional auth header needed sending x authtoken to s3 will fail