> For the complete documentation index, see [llms.txt](https://docs.pending.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.pending.ai/api-reference/pai-retro/retrosynthesis-engines.md). Agents can also search and read this documentation through its [MCP server](https://docs.pending.ai/~gitbook/mcp).

# Retrosynthesis Engines

Explore the various engines available for retrosynthesis

Pending AI offers a novel Deep-Learning MCTS **Retrosynthesis** platform for synthetic planning. An *engine* provides the underlying architecture and functional procedure used for building complex multi-step synthetic routes. When submitting a query molecule for assessing synthetic accessibility, an engine must be specified using its respective `id` field. **Considerations**

* An engine requires significant computational resources affected by different parameters when completing a Retrosynthesis job. Large screening campaigns are queued onto identical engine instances, potentially leading to longer wait times for screening results. - Engine selection can significantly impact the diversity of the generated synthetic routes. Try different engines to yield varied synthetic routes. See [here](https://docs.pending.ai/capabilities/synthetic-accessibility) for more information on our **Retrosynthesis** capability.

## List Engines

> Retrieve a list of Engine resources using offset-based pagination.\
> See the returned \`data\` field for more information about the Engine\
> resources. Use additional \`metadata\` and \`links\` fields to navigate\
> the paginated resources.

```json
{"openapi":"3.1.0","info":{"title":"Pending AI Retrosynthesis API","version":"v1.11.4"},"tags":[{"name":"Engines","description":"Pending AI offers a novel Deep-Learning MCTS **Retrosynthesis** platform for synthetic planning. An *engine* provides the underlying architecture and functional procedure used for building complex multi-step synthetic routes. When submitting a query molecule for assessing synthetic accessibility, an engine must be specified using its respective `id` field.\n**Considerations**\n- An engine requires significant computational resources affected by different parameters when completing a Retrosynthesis job. Large screening campaigns are queued onto identical engine instances, potentially leading to longer wait times for screening results. - Engine selection can significantly impact the diversity of the generated synthetic routes. Try different engines to yield varied synthetic routes.\nSee [here](https://docs.pending.ai/capabilities/synthetic-accessibility) for more information on our **Retrosynthesis** capability."}],"servers":[{"url":"https://api.pending.ai/retro/v2","description":"Pending AI API Server"}],"security":[{"oauth":[]},{"token":[]}],"components":{"securitySchemes":{"oauth":{"type":"oauth2","description":"Pending AI OAuth2 authentication.","flows":{"authorizationCode":{"refreshUrl":"https://auth.pending.ai/oauth/token","scopes":{"openid":"Required for OpenID Connect sign-in","profile":"Access to the user's basic profile information","email":"Access to the user's email address","offline_access":"Request a refresh token"},"authorizationUrl":"https://auth.pending.ai/authorize","tokenUrl":"https://auth.pending.ai/oauth/token"}}},"token":{"type":"http","description":"Pending AI authentication access token.","scheme":"bearer","bearerFormat":"JWT"}},"schemas":{"OffsetPage_Engine_":{"properties":{"object":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z_-]+$","title":"Object","description":"The named type for the resource.","default":"list"},"data":{"items":{"$ref":"#/components/schemas/Engine"},"type":"array","maxItems":100,"minItems":0,"title":"Data","description":"List of items for the current page. The number of items is not guaranteed\nto match the requested `limit` as fewer items may be available."},"metadata":{"$ref":"#/components/schemas/OffsetPageMetadata","title":"Metadata"},"links":{"$ref":"#/components/schemas/PageLinks","title":"Links"}},"type":"object","required":["metadata","links"],"title":"OffsetPage[Engine]"},"Engine":{"properties":{"id":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Id","description":"Unique identifier for a resource."},"object":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z_-]+$","title":"Object","description":"The named type for the resource.","default":"engine"},"name":{"type":"string","maxLength":512,"minLength":1,"pattern":"^.*\\S.*$","title":"Name","description":"Name of the resource. The name is a human-readable identifier and\nis not required to be unique. The value can be used for display\npurposes."},"last_alive":{"type":"string","format":"date-time","title":"Last Alive","description":"A timestamp for when the engine was last active."},"queue_length":{"type":"integer","minimum":0,"title":"Queue Length","description":"Approximate number of jobs currently queued or in-flight for\nthis engine, read directly from its SQS queue. An engine with\nno jobs submitted yet has no queue at all, which reads as 0.","default":0},"suspended":{"type":"boolean","title":"Suspended","description":"Indicates whether the engine is suspended, as in the `last_alive`\ntimestamp is older than 7 days.","readOnly":true}},"type":"object","required":["id","name","suspended"],"title":"Engine","description":"Engines are computational resources used for retrosynthesis planning.\n\nThey encapsulate the deep-learning infrastructure and algorithms employed\nto generate retrosynthetic routes for a given target molecule.\n\nEach engine has a name and a last-alive timestamp, indicating its most\nrecent use. The time required for a retrosynthesis job can vary and depends\non the engine's load and the complexity of the target molecule. Engines that\nhave not been active for a specified duration are marked as suspended."},"OffsetPageMetadata":{"properties":{"has_next":{"type":"boolean","title":"Has Next","description":"Indicates if there is a next page of results. If true, the next set of\nresults can be fetched using `next_cursor` to populate the `after`\nfield in the next request, or requesting the next page.","default":false},"has_prev":{"type":"boolean","title":"Has Prev","description":"Indicates if there is a previous page of results. If true, the previous\nset of results can be fetched using `prev_cursor` to populate the\n`before` field in the next request, or requesting the previous page.","default":false},"total_items":{"anyOf":[{"type":"integer","description":"If provided, indicates the total number of items available across all\npages. This is useful for determining the page number and size when\niterating over all pages."},{"type":"null"}],"title":"Total Items"}},"type":"object","title":"OffsetPageMetadata","description":"Metadata that contains state information for offset-based pages."},"PageLinks":{"properties":{"self":{"type":"string","maxLength":100000,"minLength":1,"title":"Self","description":"Relative URL path for the current page of results. This can be used to\nfetch the same page of results again from the API."},"next":{"anyOf":[{"type":"string","maxLength":100000,"minLength":1,"description":"Relative URL path for the next page of results. This can be used to\nfetch the next page of results from the API."},{"type":"null"}],"title":"Next"},"prev":{"anyOf":[{"type":"string","maxLength":100000,"minLength":1,"description":"Relative URL path for the previous page of results. This can be used to\nfetch the previous page of results from the API."},{"type":"null"}],"title":"Prev"}},"type":"object","required":["self"],"title":"PageLinks","description":"Links that contain information about the pagination state."},"RequestValidationErrorContent":{"description":"A request or response encountered a validation error when enforcing field constraints. Refer to `error.details` to resolve individual errors. For any unexpected validation errors, contact Pending AI support via email at [support@pending.ai](mailto:support@pending.ai).","properties":{"status":{"default":"error","description":"Status of the request.","enum":["error","success"],"title":"Request Status","type":"string"},"status_code":{"description":"Response status code received for the request.","title":"Status Code","type":"integer"},"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"description":"A unique ID given to each request.","title":"Request ID"},"error":{"anyOf":[{"$ref":"#/components/schemas/RequestValidationErrorInfo"},{"type":"null"}],"default":null,"description":"Response content containing extra information for an error.","title":"Error Information"}},"required":["status_code"],"title":"Request Validation Error","type":"object"},"RequestValidationErrorInfo":{"description":"Response content containing extra information for an error.","properties":{"code":{"description":"Short identifier code to classify the error.","title":"Code","type":"string"},"timestamp":{"description":"Timestamp of when the error occurred.","format":"date-time","title":"Timestamp","type":"string"},"path":{"description":"Request path for where the error occurred.","title":"Request Path","type":"string"},"message":{"default":null,"description":"Message associated with the encountered error.","title":"Message"},"details":{"anyOf":[{"items":{"$ref":"#/components/schemas/RequestValidationErrorInfoDetails"},"type":"array"},{"type":"null"}],"default":null,"description":"Validation errors with extra information.","title":"Detailed Message"}},"required":["code","path"],"title":"Error Information","type":"object"},"RequestValidationErrorInfoDetails":{"description":"An individual validation error with extra information.","properties":{"location":{"default":null,"description":"One or more parameters for where the validation failed.","title":"Validation Location"},"error_type":{"default":null,"description":"A description of the validation constraint that was broken.","title":"Constraint Type"}},"title":"Detailed Error Content","type":"object"}}},"paths":{"/engines":{"get":{"tags":["Engines"],"summary":"List Engines","description":"Retrieve a list of Engine resources using offset-based pagination.\nSee the returned `data` field for more information about the Engine\nresources. Use additional `metadata` and `links` fields to navigate\nthe paginated resources.","operationId":"retrieve_engine_list_engines_get","parameters":[{"description":"The page number to retrieve.","required":false,"schema":{"type":"integer"},"name":"page","in":"query"},{"description":"The maximum number of items to return per page.","required":false,"schema":{"type":"integer"},"name":"limit","in":"query"}],"responses":{"200":{"description":"Returns a list of Engines.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OffsetPage_Engine_"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","description":"Not `BaseErrorContent`: see the examples."}}}},"422":{"description":"Request validation failed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestValidationErrorContent"}}}}}}}}}
```
