Does anyone know how to get the image url from the $meta object of another generator? I think there’s an /api/ fetch I can do for it, but that stuff isn’t documented anywhere, I don’t think.
The endpoint for getting the generator stats/metadata is
https://perchance /api/getGeneratorStats?names={names}
, it would return a list of data based on the generator names inputted and it would give a metadata property per generator that you can access.Here is an example of using it: https://perchance.org/generator-list-with-stats-2-template#edit
Ah cool… thanks!
Do you know if there’s anywhere documenting
/api/
? Or at least listing endpoints/params so I can test and write my own docs for it?No, I don’t think there is. The public ones that I’ve seen are:
api/getGeneratorScreenshot?generatorName=name
- for generator screenshotsapi/getGeneratorList?max=num
- for the general generator list in the/generators
pageapi/getGeneratorStats?names=name1,name2
- for individual stats as seen from https://perchance.org/generator-list-with-stats-2-template#editapi/downloadGenerator?generatorName=name
- from the download-button-plugin
I’ve just added documentation for all the public APIs here: https://perchance.org/advanced-tutorial Thanks!
I don’t suppose you could add an id to that
<h2>
could you? So we can link people direct to that section? 😉Done, thanks!
👍