Help with Apify API: Getting Input Schema or OpenAPI Schema for each Agent.
hi Devs. anyone knows how can i get the input schema of an Actor? i've being trying this for several months with no success 🫠(Also works the OpenAPI Schema).
I'm building an AI app that use Apify as backend for tools, obviously the users need to create an Apify Account for making this work. i know i need the ActorID, but from there i don't know what to do because when i want to Run Synchronous this agent i can't because its asking me for that input schema that i don't know where to find.
The best result its a way to getting the openapi schema or input schema for each Agent using user's credentials.
1 Reply
afraid-scarlet•12mo ago
Hello. We do not have a way to do this with a single call, but you can do it with this flow:
1. GET Request to
https://api.apify.com/v2/acts/<author_name>~<actor_name>
This will return a JSON object with a taggedBuilds
field, which contains the build with their IDs.
2. GET Request to
https://api.apify.com/v2/actor-builds/<build_id>
You then use the build id you found in the first request to compose the second request, and in the response you'll get a JSON object with inputSchema
.