# Client Credential per IoT Device

**URL:** <https://community.auth0.com/t/client-credential-per-iot-device/21028>\
**Category:** Get Help\
**Tags:** machine-to-machine\
**Created:** [February 6, 2019, 11:56pm UTC](https://community.auth0.com/t/client-credential-per-iot-device/21028 "2019-02-06T23:56:21Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![brennan.roberts](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@brennan.roberts](https://community.auth0.com/u/brennan.roberts)\
**Post date:** [February 6, 2019, 11:56pm UTC](https://community.auth0.com/t/client-credential-per-iot-device/21028/1 "2019-02-06T23:56:21Z")

</div>

On the topic of IoT devices, [this Auth0 blog post](https://auth0.com/blog/using-m2m-authorization/) states

> …you use the client credentials grant, giving each IoT device its own client ID and client secret

I can’t find a way to give each IoT device it’s own client ID and secret without creating a whole new machine-to-machine application, which seems like an odd organizational structure and makes it possible to accidentally give different devices different scopes. How is this use case expected to be supported?

---

<div class="post-metadata">

**Author:** ![brennan.roberts](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@brennan.roberts](https://community.auth0.com/u/brennan.roberts)\
**Post date:** [February 7, 2019, 12:16am UTC](https://community.auth0.com/t/client-credential-per-iot-device/21028/2 "2019-02-07T00:16:31Z")

</div>

To add a bit of context, “device” in our case refers to a kiosk application that we’d like to give heightened privileges to.

---

<div class="post-metadata">

**Author:** ![john.gateley](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/john.gateley/32/10879_2.png) [@john.gateley](https://community.auth0.com/u/john.gateley)\
**Post date:** [February 7, 2019, 4:44pm UTC](https://community.auth0.com/t/client-credential-per-iot-device/21028/4 "2019-02-07T16:44:11Z")

</div>

I would start by looking at the management API for creating Grants and Clients.

John

---

<div class="post-metadata">

**Author:** ![konrad.sopala](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/konrad.sopala/32/13516_2.png) [@konrad.sopala](https://community.auth0.com/u/konrad.sopala)\
**Post date:** [February 8, 2019, 7:46am UTC](https://community.auth0.com/t/client-credential-per-iot-device/21028/5 "2019-02-08T07:46:26Z")

</div>

In addition to what John said, here are our docs on choosing the best flow:

> **[Which OAuth 2.0 Flow Should I Use?](https://auth0.com/docs/get-started/authentication-and-authorization-flow/which-oauth-2-0-flow-should-i-use)**
>
> Learn how to identify the proper OAuth 2.0 flow for your use case.

> **[Application Grant Types](https://auth0.com/docs/get-started/applications/application-grant-types)**
>
> Describes grant types and how they relate to applications.

---

<div class="post-metadata">

**Author:** ![konrad.sopala](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/konrad.sopala/32/13516_2.png) [@konrad.sopala](https://community.auth0.com/u/konrad.sopala)\
**Post date:** [February 12, 2019, 3:13pm UTC](https://community.auth0.com/t/client-credential-per-iot-device/21028/6 "2019-02-12T15:13:47Z")

</div>

Have you had a chance to go through the docs I provided?

---

<div class="post-metadata">

**Author:** ![brennan.roberts](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@brennan.roberts](https://community.auth0.com/u/brennan.roberts)\
**Post date:** [February 12, 2019, 7:34pm UTC](https://community.auth0.com/t/client-credential-per-iot-device/21028/7 "2019-02-12T19:34:58Z")

</div>

Thanks, all. Client credentials grant is definitely the correct flow based on our situation. Sounds like the admin UI makes our situation a bit clunky, but we could script or write our own API for it using the management API.

---

<div class="post-metadata">

**Author:** ![konrad.sopala](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/konrad.sopala/32/13516_2.png) [@konrad.sopala](https://community.auth0.com/u/konrad.sopala)\
**Post date:** [February 13, 2019, 11:42am UTC](https://community.auth0.com/t/client-credential-per-iot-device/21028/8 "2019-02-13T11:42:26Z")

</div>

Totally glad that you’re closer to your solution now!

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [February 28, 2019, 11:42am UTC](https://community.auth0.com/t/client-credential-per-iot-device/21028/9 "2019-02-28T11:42:30Z")

</div>

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.
