So, I think I’m close to having DNS Add service working, as a first attempt at authorised API but what I expected of serviceHomeDirPath is giving a
*ERRNO: -1502* FfiError::PathNotFound
The authorisation looks to be working, it just looks to be stuck finding the path.
The example in the docs https://api.safedev.org/dns/add-service.html
suggests “serviceHomeDirPath”: “/websites/test”
but I wondered that would be now “serviceHomeDirPath”: “/public/example” where I have a folder existing.
The error seems to spawn from trying to navigate to /public
Traversing to dir with name: public
FFI cross-boundary error propagation:
*ERRNO: -1502* FfiError::PathNotFound
So, having tried simply also “serviceHomeDirPath”: “/example” I’m stumped wondering why it can’t find /public or the existing /public/example to then map the suggested new service to.
Example of the PUT I’m using is:
put_heads {"Connection": "close", "Authorization": "Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6ImhXRkR4Q0JsVkxqVVFUL2hialZTTjIzQWpuN2RMNVhnUE9wMko2NWt3bjg9IiwiaWF0IjoxNDc3MjQ2MTM4fQ.NFa0uJqyQvnIK9H_IJqi6z0VdkQzBVLp-rJfU_mqGBc", "Content-Type": "application/json"}
put_body AddServiceBody { longName: "testtest", serviceName: "service", rootPath: "drive", serviceHomeDirPath: "/public/example/" }
Add service: 400 Bad Request
What am I missing?