-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document required indentation for policy creation #211
Comments
Hi @bwaz, can you show (exactly) how you're calling the API? If you're using cURL with the
E.g., if you run
Notice the whitespace between the package directive and import directive has been dropped. If you are using cURL, I recommend the |
I'm calling like this: |
OK, I will update the docs to include a note about this. Thanks for filing the issue! |
Update documents to reflect required indentation with package definitions for the REST examples
http://www.openpolicyagent.org/documentation/references/rest/
working example:
package opa.examples
<white space>import request.example.a
failing example:
package opa.examples
import request.example.a
error output:
{ "Code": 400, "Message": "opaexample:1: expected rule (request.example.a must be declared inside a rule)" }
The text was updated successfully, but these errors were encountered: