Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

"spec_version" property #237

Open
magsen opened this issue Aug 8, 2022 · 0 comments
Open

"spec_version" property #237

magsen opened this issue Aug 8, 2022 · 0 comments

Comments

@magsen
Copy link

magsen commented Aug 8, 2022

When getting a specific object or a list of object ( GET {api-root}/collections/{id}/objects/{object-id}/ ), the property field "spec_version" is equals to the "type", it should be "2.1" (or others version spec).

OBSERVED:

{
  "more": false,
  "objects": [
    {
      "id": "marking-definition--613f2e26-407d-48c7-9eca-b8e91df99dc9",
      "type": "marking-definition",
      "spec_version": "marking-definition",
      "name": "TLP:WHITE",
      "created": "2017-01-20T00:00:00.000Z",
      "modified": "2022-07-29T13:42:44.472979Z",
      "definition": {
        "tlp": "white"
      },
      "definition_type": "tlp"
    }
  ]
}

EXPECTED:

{
  "more": false,
  "objects": [
    {
      "id": "marking-definition--613f2e26-407d-48c7-9eca-b8e91df99dc9",
      "type": "marking-definition",
      "spec_version": "2.1",
      "name": "TLP:WHITE",
      "created": "2017-01-20T00:00:00.000Z",
      "modified": "2022-07-29T13:42:44.472979Z",
      "definition": {
        "tlp": "white"
      },
      "definition_type": "tlp"
    }
  ]
}

You may investigate theses lines:

"spec_version": obj.type,

"spec_version": obj.type,

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant