Streaming live at 10am (PST)

How do I find my Collection ID?


#1

I’m using @samliew’s awesome exporter here: http://api-tester.webflow.io/

But I’m having trouble figuring out what my Collection ID’s are, it doesn’t really say and it says that I need alphanumeric ones? Some of my ID’s seem to have hyphens, such as “related-publications”


#2

GET /sites/:site_id/collections

Will return all collections with their IDs I believe.

https://developers.webflow.com/#list-collections


#3

Hi @vincent, where do I type GET /sites/:site_id/collections – is it in a javascript file? I don’t understand the overall structure, and I’m struggling a basic template to learn from.


#4

I honestly have no clue, I googled it and I hoped you wouldn’t answer back :smiley: I’m not sure I’d pass a Turing test.


#5

You’ll have to run this URL to get a list of all sites’ IDs that you can retrieve with your API key

/sites?access_token=[your-access-token]

Then you’ll have to run this to get a list of all collections’ IDs in the site

/sites/[your-site-id]/collections?access_token=[your-access-token]

Then you’ll receive a response like this. An ID is similar to the ones in the yellow highlighted box:

Screenshot_2018-02-26_090255

Here’s the full reference

http://developers.webflow.com

And how to work with an API

https://schoolofdata.org/2013/11/18/web-apis-for-non-programmers/


#6

Thank you, this is exactly what I needed! :pray:


#7

Hey @samliew, I’m not sure if the Webflow API is down, but when I type into the URL bar:

https://api.webflow.com/

I get this error. It doesn’t seem quite right, and obviously, nothing else is working either. Even when I type:

https://api.webflow.com/sites?access_token=[my-access-token]

I also get errors. Am I missing something, or does it seem the API is down?


#8

Aha! So this is how to set the version:

https://api.webflow.com/sites?api_version=1.0.0&access_token=[my-collection-id]

It works!


#9

You’re welcome!