cURL
curl --request POST \ --url https://apigcp.trynia.ai/v2/packages/read \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "registry": "<string>", "package_name": "<string>", "filename_sha256": "<string>", "start_line": 123, "end_line": 123, "version": "<string>" } '
{ "detail": [ { "loc": [ "<string>" ], "msg": "<string>", "type": "<string>" } ] }
Read specific lines from a package source file. Max 200 lines per request.
API key must be provided in the Authorization header
Request model for reading package file
Registry: crates_io, golang_proxy, npm, py_pi, or ruby_gems
Package name
File SHA256
Start line (1-based)
End line (1-based)
Package version
Successful Response
Was this page helpful?
Suggestions
Contact support