@lap v0.3
# Machine-readable API spec. Each @endpoint block is one API call.
@api Policies System API
@base https://apiexamples.vtexcommercestable.com.br
@auth ApiKey X-VTEX-API-AppKey in header | ApiKey X-VTEX-API-AppToken in header | ApiKey VtexIdclientAutCookie in header
@common_fields {Content-Type: str=application/json, Accept: str=application/json}
@endpoints 6
@toc api(6)

@endpoint GET /api/policy-engine/policies
@returns(200)

@endpoint POST /api/policy-engine/evaluate
@required {resource: str, context: map}
@returns(200)

@endpoint GET /api/policy-engine/policies/{id}
@required {id: str}
@returns(200)

@endpoint POST /api/policy-engine/policies/{id}
@required {id: str, name: str, description: str, statements: [map{effect!: str, actions: [map], resource: str, condition: map}]}
@optional {status: str}
@returns(200)

@endpoint PUT /api/policy-engine/policies/{id}
@required {id: str, name: str, description: str, statements: [map{effect!: str, actions: [map], resource: str, condition: map}]}
@optional {status: str}
@returns(200)

@endpoint DELETE /api/policy-engine/policies/{id}
@required {id: str}
@returns(200)

@end
