# API

**URL:** <https://community.hubspot.com/t/api/51619>\
**Category:** APIs & Integrations\
**Tags:** contacts\
**Created:** [February 16, 2022, 7:34am UTC](https://community.hubspot.com/t/api/51619 "2022-02-16T07:34:02Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![MickaelRANDRIAN](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/mickaelrandrian/32/31184_2.png) [@MickaelRANDRIAN](https://community.hubspot.com/u/MickaelRANDRIAN)\
**Post date:** [February 16, 2022, 7:34am UTC](https://community.hubspot.com/t/api/51619/1 "2022-02-16T07:34:02Z")

</div>

hello! this is a beginner question  
How to use the endpoints of the hubspot api  
thanks

---

<div class="post-metadata">

**Author:** ![albertsg](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/albertsg/32/99473_2.png) [@albertsg](https://community.hubspot.com/u/albertsg)\
**Post date:** [February 16, 2022, 2:47pm UTC](https://community.hubspot.com/t/api/51619/2 "2022-02-16T14:47:43Z")

</div>

Hi @MickaelRANDRIAN, first you need to get your API key by going to Settings --\> Integrations --\> API key.

Once you have the API key, you can create any script to connect with Hubspot’s API and do whatever you want 🙂

I have an example in one of my GitHub repos that might be useful for you to get started and to understand a bit the process. Here’s the link: [hubspot-api-scripts/scripts/tag-update.js at master · albertsg/hubspot-api-scripts · GitHub](https://github.com/albertsg/hubspot-api-scripts/blob/master/scripts/tag-update.js)

You can also do test calls from the API documentation website, see for example: [Accounts Dashboard | HubSpot](https://developers.hubspot.com/docs/api/cms/blog-post)

---

<div class="post-metadata">

**Author:** ![dennisedson](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/dennisedson/32/28044_2.png) [@dennisedson](https://community.hubspot.com/u/dennisedson)\
**Post date:** [February 16, 2022, 6:23pm UTC](https://community.hubspot.com/t/api/51619/3 "2022-02-16T18:23:05Z")

</div>

Gonna have to go spy on the repo, @albertsg !

---

<div class="post-metadata">

**Author:** ![albertsg](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/albertsg/32/99473_2.png) [@albertsg](https://community.hubspot.com/u/albertsg)\
**Post date:** [February 16, 2022, 7:08pm UTC](https://community.hubspot.com/t/api/51619/4 "2022-02-16T19:08:20Z")

</div>

@dennisedson Not much to see yet, just some scripts I use from time to time to automatize tasks or to achieve things I cannot do through Hubspot’s UI, like updating the domain of several landing pages at once (the only “official” way to do this is updating landing pages one by one manually -- or changing the primary domain but this can only be used once and not very recommended) 😁  
And since sharing is caring, I like to share code that might be useful for other Hubspot users.
