Skip to content

[BUG] Connector API docs: auditLog createdBy does not match format #32

@MrSerth

Description

@MrSerth

Describe the bug
When listing Relationships via GET /api/v2/Relationships, the returned auditLog entries aren't API-conform: According to the API schema the RelationshipAuditLogEntry's content createdBy should be of format date-time [1]. However, it rather looks like a did.

[1] https://github.com/nmshd/connector/blob/85d94e75fb126a8c05fcd67dadd336e125b32fe6/src/modules/coreHttpApi/openapi.yml#L6032-L6035

To Reproduce

  1. Load the API schema with (or any other validation tool):
schema = JSONSchemer.openapi(YAML.safe_load_file(<path-to-file>), permitted_classes: [Time, Date]))
  1. Query relationship templates via GET api/v2/Relationships
  2. Pass the one of the results to:
schema.valid?(<first-result>)
  1. To see the error details, pass the result of one of the relationships to:
puts schema.validate(<first-result>).first.fetch('error')
  1. See error
value at `/auditLog/0/createdBy` does not match format: date-time

Expected behavior
Please update the OpenAPI docs to represent the API response. Probably, $ref: "#/components/schemas/Address" is desired.

Environment

  • Product: Connector
  • Version: 6.13.1(API: 3.1.0)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions