I'm having issues Authenticating with the Rest API.
I am running TrueNAS-12.0-U2.1, and everything is working as expected except for the API.
I have tried both Basic authentication and Bearer Authentication, my goal is to use restsharp but I have also tried python and curl and all of them return 401: Unauthorized.
I have tried most methods of authenticating with curl but they generally go something like this.
curl -H 'Accept: application/json' -H "Authorization: Bearer 1-Pe9VwiV5B70yrq8kM8RBLAHBLAHBLAHBLAHalAWIWtr0" http://10.30.163.35/api/v2.0/pool
I have also tried Basic with username:password as Base64.
Does anyone have any idea what I am doing wrong? Or does anyone have an example curl command that works?
I am running TrueNAS-12.0-U2.1, and everything is working as expected except for the API.
I have tried both Basic authentication and Bearer Authentication, my goal is to use restsharp but I have also tried python and curl and all of them return 401: Unauthorized.
I have tried most methods of authenticating with curl but they generally go something like this.
curl -H 'Accept: application/json' -H "Authorization: Bearer 1-Pe9VwiV5B70yrq8kM8RBLAHBLAHBLAHBLAHalAWIWtr0" http://10.30.163.35/api/v2.0/pool
I have also tried Basic with username:password as Base64.
Does anyone have any idea what I am doing wrong? Or does anyone have an example curl command that works?