Pregunta

I am trying to use the PushBullet API but I am having some problems with it authenticating my API Key mainly because I am not sure how to properly make a POST to the API.

I tried researching online but I couldn't find what -u means. Does this mean it should go in the header or apart of the data?

curl https://api.pushbullet.com/api/pushes \
      -u API_KEY: \
      -d device_iden=u1qSJddxeKwOGuGW \
      -d type=note \
      -d title=Title \
      -d body=Body \
      -X POST

I tried to do a Postman like so (I blocked out where the key and device go): enter image description here

What am I doing wrong?

¿Fue útil?

Solución

I figured it out I needed to add Authorization to the header. Then in the header I used the key as the username. All working now!

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top