# POST Device attributes from POSTMAN

**URL:** <https://forums.losant.com/t/post-device-attributes-from-postman/1743>\
**Category:** Help\
**Created:** [April 24, 2019, 7:14am UTC](https://forums.losant.com/t/post-device-attributes-from-postman/1743 "2019-04-24T07:14:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![sivasankari\_s](https://avatars.discourse-cdn.com/v4/letter/s/d26b3c/32.png) [@sivasankari\_s](https://forums.losant.com/u/sivasankari_s)\
**Post date:** [April 24, 2019, 7:14am UTC](https://forums.losant.com/t/post-device-attributes-from-postman/1743/1 "2019-04-24T07:14:26Z")

</div>

Hi,  
This is sivasankari .I am a new learner for Losant framework.please  
send sample syntax of post device attributes from POSTMAN

---

<div class="post-metadata">

**Author:** ![JuliaKempf](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/juliakempf/32/2446_2.png) [@JuliaKempf](https://forums.losant.com/u/JuliaKempf)\
**Post date:** [April 24, 2019, 2:39pm UTC](https://forums.losant.com/t/post-device-attributes-from-postman/1743/2 "2019-04-24T14:39:38Z")

</div>

Hi @sivasankari_s,

Updating device attributes requires the use of [Device Patch](https://docs.losant.com/rest-api/device/#patch), while sending state for those attributes would be done with [Device State](https://docs.losant.com/rest-api/device/#send-state). Here is a walkthrough for Device Patch:

**Device Patch**

I [create a device](https://docs.losant.com/devices/overview/#adding-a-device) called Thermostat with two attributes: temperature and humidity.

 ![53%20AM](https://us1.discourse-cdn.com/flex015/uploads/getstructure/original/2X/a/a5795c33badb9f9ef43a56a3477c0ba6bd9f190b.png)

I [create an application token](https://docs.losant.com/applications/application-tokens/#generating-an-api-token) for use in Postman.  
 ![36%20AM](https://us1.discourse-cdn.com/flex015/uploads/getstructure/original/2X/c/c8195d9130cf304f5c7a259bd7cd82015ae0d38e.png)

Over on Postman, I set my request to `PATCH` and put in my request URL that holds my application ID and device ID. I set my authentication type to Bearer Token and paste in the token I generated in Losant.  
 ![58%20AM](https://us1.discourse-cdn.com/flex015/uploads/getstructure/original/2X/5/50bcfdb3d4308aee68bf0dbf2d0549a6dd7ae629.png)

Then I set my Headers for this request:

 ![18%20AM](https://us1.discourse-cdn.com/flex015/uploads/getstructure/original/2X/7/7501826332f471a709cd3a01d09a66870fab342d.png)

Then over in the body, I specify the attributes I would like this device to have:

 ![34%20AM](https://us1.discourse-cdn.com/flex015/uploads/getstructure/original/2X/1/1594277e1bdffb90aed7e71b00c6d1f33e1c5c60.png)

And back on Losant, I can see that my `PATCH` was successful, and my previous attributes have been overwritten and `celsius` is my only attribute.

 ![27%20AM](https://us1.discourse-cdn.com/flex015/uploads/getstructure/original/2X/2/20525160b658af0a29328f19bc87d82dc31d28fa.png)

Let me know how else I can help!  
Julia

---

<div class="post-metadata">

**Author:** ![sivasankari\_s](https://avatars.discourse-cdn.com/v4/letter/s/d26b3c/32.png) [@sivasankari\_s](https://forums.losant.com/u/sivasankari_s)\
**Post date:** [April 25, 2019, 7:10am UTC](https://forums.losant.com/t/post-device-attributes-from-postman/1743/3 "2019-04-25T07:10:03Z")

</div>

Thank you very much Julia,  
I have two attributes like the followings  
“attributes”: [  
{  
“name”: “phonename”,  
“dataType”: “string”  
},  
{  
“name”: “phonestatus”,  
“dataType”: “number”  
}  
]

I want to pass the attributes value(Parameters) from POSTMAN.

Example:POST [https://5ca5f7f18b62290008d0e84d.onlosant.com/devices/deviceid/](https://5ca5f7f18b62290008d0e84d.onlosant.com/devices/deviceid/)  
Here I want to POST Data of two attributes(Phonename=“Iphone7” Phonestatsus=1)  
from POSTMAN.  
please send me samples

Thanks  
Sivasankari S
