Skip to content

Common Design Model for Cloud Event datacontenttype field #192

@rartych

Description

@rartych

Problem description
API Design Guidelines requirement is that datacontenttype field is media-type that describes the event payload encoding, must be application/json for CAMARA APIs
In https://github.com/camaraproject/Commonalities/blob/main/artifacts/notification-as-cloud-event.yaml it is defined as follows:

datacontenttype:
          type: string
          description: 'media-type that describes the event payload encoding, must be "application/json" for CAMARA APIs'

Possible evolution
Define required value as enum - as the only possible value is "application/json"

Alternative solution

Additional context
The similar specversion field is defined as enum with PR:

The datacontenttype field is optional , specversion field is mandatory

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions