Skip to content

Policy Store API: Get policy by ID #803

@dsmf

Description

@dsmf

As Trace-X
I want an API endpoint to get a policy by ID
so that I can get a policy with its details and list of associated business partner numbers.

Hints / Details

example:

GET /irs/policies/a1a140d2-eb9a-4ec2-a95b-b9bf52596848

=>

{
	"validUntil": "2025-12-12T23:59:59.999Z",
	"payload": {
		"@context": {
			"odrl": "http://www.w3.org/ns/odrl/2/"
		},
		"@id": "policy1",
		"policy": {
			"policyId": "policy1",
			"createdOn": "2024-07-11T10:39:48.4206493Z",
			"validUntil": "2025-12-12T23:59:59.999Z",
			"permissions": [
				...
			]
		}
	},
	"bpn": [
		"BPNL1234567890AB",
		"BPNL1234567890CD",
		"BPNL9834567890CD"
	]
}

Acceptance Criteria

  • query by existing policy ID returns 200 OK with policy (see example under hints)
  • result includes list of associated business partner numbers
  • query by non-existing policy ID returns 404 with message "Policy not found"

Out of Scope

  • ...

Metadata

Metadata

Assignees

No one assigned

    Labels

    apiapi specific issuespolicy_storeIssues regarding the IRS policy store.

    Type

    No type

    Projects

    Status

    backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions