Submit compact PubChem PUG REST requests for compound properties, descriptions, assay summaries, and substance metadata. Use when a user wants concise PubChem summaries
scripts/rest_request.py for all PubChem PUG calls.base_url=https://pubchem.ncbi.nlm.nih.gov/rest/pug.max_items=10.... in tool previews as UI truncation, not literal request content.save_raw=true and report the saved file path.base_url, pathmethod, params, headers, json_body, form_body, record_path, response_format, max_items, max_depth, timeout_sec, save_raw, raw_output_path{"base_url":"https://pubchem.ncbi.nlm.nih.gov/rest/pug","path":"compound/name/aspirin/property/MolecularFormula,MolecularWeight/JSON","record_path":"PropertyTable.Properties"}{"base_url":"https://pubchem.ncbi.nlm.nih.gov/rest/pug","path":"compound/cid/2244/description/JSON","record_path":"InformationList.Information","max_items":10}{"base_url":"https://pubchem.ncbi.nlm.nih.gov/rest/pug","path":"assay/aid/1706/summary/JSON","record_path":"AssaySummaries","max_items":10}ok, source, path, method, status_code, warnings, and either compact records or a compact summary.raw_output_path when save_raw=true.ok=false with error.code and error.message.echo '{"base_url":"https://pubchem.ncbi.nlm.nih.gov/rest/pug","path":"compound/name/aspirin/property/MolecularFormula,MolecularWeight/JSON","record_path":"PropertyTable.Properties"}' | python scripts/rest_request.py
scripts/rest_request.py.