datasets

Dataset related operations

List or search all datasets

GET//www.data.gouv.fr/api/1/datasets/
Query parameters
Header parameters
Response

Success

Body
dataarray of Dataset (object)

The page data

next_pagestring

The next page URL if exists

page*integer

The current page

page_size*integer

The page size used for pagination

previous_pagestring

The previous page URL if exists

total*integer

The total paginated items

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "data": [
    {
      "acronym": "text",
      "archived": "2024-10-23T15:28:25.435Z",
      "badges": [
        {
          "kind": "text"
        }
      ],
      "community_resources": [
        {
          "checksum": {
            "type": "sha1",
            "value": "text"
          },
          "created_at": "2024-10-23T15:28:25.435Z",
          "description": "text",
          "filetype": "file",
          "format": "text",
          "harvest": {
            "created_at": "2024-10-23T15:28:25.435Z",
            "modified_at": "2024-10-23T15:28:25.435Z",
            "uri": "text"
          },
          "id": "text",
          "internal": {
            "created_at_internal": "2024-10-23T15:28:25.435Z",
            "last_modified_internal": "2024-10-23T15:28:25.435Z"
          },
          "last_modified": "2024-10-23T15:28:25.435Z",
          "latest": "text",
          "mime": "text",
          "preview_url": "text",
          "schema": {
            "name": "text",
            "url": "text",
            "version": "text"
          },
          "title": "text",
          "type": "main",
          "url": "text",
          "dataset": {
            "class": "text",
            "id": "text",
            "acronym": "text",
            "page": "text",
            "title": "text",
            "uri": "text"
          },
          "organization": {
            "class": "text",
            "id": "text",
            "acronym": "text",
            "badges": [
              {
                "kind": "text"
              }
            ],
            "logo": "text",
            "logo_thumbnail": "text",
            "name": "text",
            "page": "text",
            "slug": "text",
            "uri": "text"
          },
          "owner": {
            "class": "text",
            "id": "text",
            "avatar": "text",
            "avatar_thumbnail": "text",
            "first_name": "text",
            "last_name": "text",
            "page": "text",
            "slug": "text",
            "uri": "text"
          }
        }
      ],
      "contact_point": {
        "email": "text",
        "id": "text",
        "name": "text",
        "organization": {
          "class": "text",
          "id": "text",
          "acronym": "text",
          "badges": [
            {
              "kind": "text"
            }
          ],
          "logo": "text",
          "logo_thumbnail": "text",
          "name": "text",
          "page": "text",
          "slug": "text",
          "uri": "text"
        },
        "owner": {
          "class": "text",
          "id": "text",
          "avatar": "text",
          "avatar_thumbnail": "text",
          "first_name": "text",
          "last_name": "text",
          "page": "text",
          "slug": "text",
          "uri": "text"
        }
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "deleted": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "featured": false,
      "frequency": "unknown",
      "frequency_date": "2024-10-23T15:28:25.435Z",
      "harvest": {
        "archived": "text",
        "archived_at": "2024-10-23T15:28:25.435Z",
        "backend": "text",
        "ckan_name": "text",
        "ckan_source": "text",
        "created_at": "2024-10-23T15:28:25.435Z",
        "dct_identifier": "text",
        "domain": "text",
        "last_update": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "remote_id": "text",
        "remote_url": "text",
        "source_id": "text",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "last_update": "2024-10-23T15:28:25.435Z",
      "license": "notspecified",
      "organization": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "badges": [
          {
            "kind": "text"
          }
        ],
        "logo": "text",
        "logo_thumbnail": "text",
        "name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      },
      "owner": {
        "class": "text",
        "id": "text",
        "avatar": "text",
        "avatar_thumbnail": "text",
        "first_name": "text",
        "last_name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      },
      "page": "text",
      "private": false,
      "resources": [
        {
          "checksum": {
            "type": "sha1",
            "value": "text"
          },
          "created_at": "2024-10-23T15:28:25.435Z",
          "description": "text",
          "filetype": "file",
          "format": "text",
          "harvest": {
            "created_at": "2024-10-23T15:28:25.435Z",
            "modified_at": "2024-10-23T15:28:25.435Z",
            "uri": "text"
          },
          "id": "text",
          "internal": {
            "created_at_internal": "2024-10-23T15:28:25.435Z",
            "last_modified_internal": "2024-10-23T15:28:25.435Z"
          },
          "last_modified": "2024-10-23T15:28:25.435Z",
          "latest": "text",
          "mime": "text",
          "preview_url": "text",
          "schema": {
            "name": "text",
            "url": "text",
            "version": "text"
          },
          "title": "text",
          "type": "main",
          "url": "text"
        }
      ],
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "slug": "text",
      "spatial": {
        "geom": {
          "coordinates": [],
          "type": "Point"
        },
        "granularity": "other",
        "zones": [
          "text"
        ]
      },
      "tags": [
        "text"
      ],
      "temporal_coverage": {
        "end": "2024-10-23T15:28:25.435Z",
        "start": "2024-10-23T15:28:25.435Z"
      },
      "title": "text",
      "uri": "text"
    }
  ],
  "next_page": "text",
  "previous_page": "text"
}

Create a new dataset

POST//www.data.gouv.fr/api/1/datasets/
Header parameters
Body
acronymstring

An optional dataset acronym

archivedstring (date-time)

The archival date if archived

badgesarray of Badge (object)

The dataset badges

community_resourcesarray of all of
contact_pointall of

The dataset's contact points

created_at*string (date-time)

This date is computed between harvested creation date if any and site's internal creation date

deletedstring (date-time)

The deletion date if deleted

description*string (markdown)

The dataset description in markdown

extrasobject

Extras attributes as key-value pairs

featuredboolean

Is the dataset featured

frequency*enum

The update frequency

Example: "unknown"
unknownpunctualcontinuoushourlyfourTimesADaythreeTimesADaysemidailydailyfourTimesAWeekthreeTimesAWeeksemiweeklyweeklybiweeklythreeTimesAMonthsemimonthlymonthlybimonthlyquarterlythreeTimesAYearsemiannualannualbiennialtriennialquinquennialirregular
frequency_datestring (date-time)

Next expected update date, you will be notified once that date is reached.

harvestall of

Dataset harvest metadata attributes

idstring

The dataset identifier

internalall of

Site internal and specific object's data

last_modified*string (date-time)

The dataset last modification date

last_update*string (date-time)

The resources last modification date

licensestring

The dataset license

metricsobject

The dataset metrics

organizationall of

The producer organization

ownerall of

The user information

page*string

The dataset page URL

privateboolean

Is the dataset private to the owner or the organization

qualityobject

The dataset quality

resourcesarray of all of
schemaall of

Reference to the associated schema

slug*string

The dataset permalink string

spatialall of

The spatial coverage

tagsarray of string
temporal_coverageall of

The temporal coverage

title*string

The dataset title

uri*string

The dataset API URI

Response

Success

Body
acronymstring

An optional dataset acronym

archivedstring (date-time)

The archival date if archived

badgesarray of Badge (object)

The dataset badges

community_resourcesarray of all of
contact_pointall of

The dataset's contact points

created_at*string (date-time)

This date is computed between harvested creation date if any and site's internal creation date

deletedstring (date-time)

The deletion date if deleted

description*string (markdown)

The dataset description in markdown

extrasobject

Extras attributes as key-value pairs

featuredboolean

Is the dataset featured

frequency*enum

The update frequency

Example: "unknown"
unknownpunctualcontinuoushourlyfourTimesADaythreeTimesADaysemidailydailyfourTimesAWeekthreeTimesAWeeksemiweeklyweeklybiweeklythreeTimesAMonthsemimonthlymonthlybimonthlyquarterlythreeTimesAYearsemiannualannualbiennialtriennialquinquennialirregular
frequency_datestring (date-time)

Next expected update date, you will be notified once that date is reached.

harvestall of

Dataset harvest metadata attributes

idstring

The dataset identifier

internalall of

Site internal and specific object's data

last_modified*string (date-time)

The dataset last modification date

last_update*string (date-time)

The resources last modification date

licensestring

The dataset license

metricsobject

The dataset metrics

organizationall of

The producer organization

ownerall of

The user information

page*string

The dataset page URL

privateboolean

Is the dataset private to the owner or the organization

qualityobject

The dataset quality

resourcesarray of all of
schemaall of

Reference to the associated schema

slug*string

The dataset permalink string

spatialall of

The spatial coverage

tagsarray of string
temporal_coverageall of

The temporal coverage

title*string

The dataset title

uri*string

The dataset API URI

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "frequency": "unknown",
      "last_modified": "2024-10-23T15:28:25.435Z",
      "last_update": "2024-10-23T15:28:25.435Z",
      "page": "text",
      "slug": "text",
      "title": "text",
      "uri": "text"
    }),
});
const data = await response.json();
Response
{
  "acronym": "text",
  "archived": "2024-10-23T15:28:25.435Z",
  "badges": [
    {
      "kind": "text"
    }
  ],
  "community_resources": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text",
      "dataset": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "page": "text",
        "title": "text",
        "uri": "text"
      },
      "organization": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "badges": [
          {
            "kind": "text"
          }
        ],
        "logo": "text",
        "logo_thumbnail": "text",
        "name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      },
      "owner": {
        "class": "text",
        "id": "text",
        "avatar": "text",
        "avatar_thumbnail": "text",
        "first_name": "text",
        "last_name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      }
    }
  ],
  "contact_point": {
    "email": "text",
    "id": "text",
    "name": "text",
    "organization": {
      "class": "text",
      "id": "text",
      "acronym": "text",
      "badges": [
        {
          "kind": "text"
        }
      ],
      "logo": "text",
      "logo_thumbnail": "text",
      "name": "text",
      "page": "text",
      "slug": "text",
      "uri": "text"
    },
    "owner": {
      "class": "text",
      "id": "text",
      "avatar": "text",
      "avatar_thumbnail": "text",
      "first_name": "text",
      "last_name": "text",
      "page": "text",
      "slug": "text",
      "uri": "text"
    }
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "deleted": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "featured": false,
  "frequency": "unknown",
  "frequency_date": "2024-10-23T15:28:25.435Z",
  "harvest": {
    "archived": "text",
    "archived_at": "2024-10-23T15:28:25.435Z",
    "backend": "text",
    "ckan_name": "text",
    "ckan_source": "text",
    "created_at": "2024-10-23T15:28:25.435Z",
    "dct_identifier": "text",
    "domain": "text",
    "last_update": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "remote_id": "text",
    "remote_url": "text",
    "source_id": "text",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "last_update": "2024-10-23T15:28:25.435Z",
  "license": "notspecified",
  "organization": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "badges": [
      {
        "kind": "text"
      }
    ],
    "logo": "text",
    "logo_thumbnail": "text",
    "name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "owner": {
    "class": "text",
    "id": "text",
    "avatar": "text",
    "avatar_thumbnail": "text",
    "first_name": "text",
    "last_name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "page": "text",
  "private": false,
  "resources": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text"
    }
  ],
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "slug": "text",
  "spatial": {
    "geom": {
      "coordinates": [],
      "type": "Point"
    },
    "granularity": "other",
    "zones": [
      "text"
    ]
  },
  "tags": [
    "text"
  ],
  "temporal_coverage": {
    "end": "2024-10-23T15:28:25.435Z",
    "start": "2024-10-23T15:28:25.435Z"
  },
  "title": "text",
  "uri": "text"
}

List all available dataset badges and their labels

GET//www.data.gouv.fr/api/1/datasets/badges/
Response

Success

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/badges/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();

List all community resources

GET//www.data.gouv.fr/api/1/datasets/community_resources/
Query parameters
Header parameters
Response

Success

Body
dataarray of CommunityResource (all of)

The page data

next_pagestring

The next page URL if exists

page*integer

The current page

page_size*integer

The page size used for pagination

previous_pagestring

The previous page URL if exists

total*integer

The total paginated items

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/community_resources/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "data": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text",
      "dataset": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "page": "text",
        "title": "text",
        "uri": "text"
      },
      "organization": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "badges": [
          {
            "kind": "text"
          }
        ],
        "logo": "text",
        "logo_thumbnail": "text",
        "name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      },
      "owner": {
        "class": "text",
        "id": "text",
        "avatar": "text",
        "avatar_thumbnail": "text",
        "first_name": "text",
        "last_name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      }
    }
  ],
  "next_page": "text",
  "previous_page": "text"
}

Create a new community resource

POST//www.data.gouv.fr/api/1/datasets/community_resources/
Header parameters
Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

datasetall of

Reference to the associated dataset

organizationall of

The producer organization

ownerall of

The user information

Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

datasetall of

Reference to the associated dataset

organizationall of

The producer organization

ownerall of

The user information

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/community_resources/', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "filetype": "file",
      "format": "text",
      "title": "text",
      "type": "main",
      "url": "text"
    }),
});
const data = await response.json();
Response
{
  "checksum": {
    "type": "sha1",
    "value": "text"
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "filetype": "file",
  "format": "text",
  "harvest": {
    "created_at": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "latest": "text",
  "mime": "text",
  "preview_url": "text",
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "title": "text",
  "type": "main",
  "url": "text",
  "dataset": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "page": "text",
    "title": "text",
    "uri": "text"
  },
  "organization": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "badges": [
      {
        "kind": "text"
      }
    ],
    "logo": "text",
    "logo_thumbnail": "text",
    "name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "owner": {
    "class": "text",
    "id": "text",
    "avatar": "text",
    "avatar_thumbnail": "text",
    "first_name": "text",
    "last_name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  }
}

Retrieve a community resource given its identifier

GET//www.data.gouv.fr/api/1/datasets/community_resources/{community}/
Path parameters
community*string

The community resource unique identifier

Query parameters
Header parameters
Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

datasetall of

Reference to the associated dataset

organizationall of

The producer organization

ownerall of

The user information

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/community_resources/{community}/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "checksum": {
    "type": "sha1",
    "value": "text"
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "filetype": "file",
  "format": "text",
  "harvest": {
    "created_at": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "latest": "text",
  "mime": "text",
  "preview_url": "text",
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "title": "text",
  "type": "main",
  "url": "text",
  "dataset": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "page": "text",
    "title": "text",
    "uri": "text"
  },
  "organization": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "badges": [
      {
        "kind": "text"
      }
    ],
    "logo": "text",
    "logo_thumbnail": "text",
    "name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "owner": {
    "class": "text",
    "id": "text",
    "avatar": "text",
    "avatar_thumbnail": "text",
    "first_name": "text",
    "last_name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  }
}

Update a given community resource

PUT//www.data.gouv.fr/api/1/datasets/community_resources/{community}/
Path parameters
community*string

The community resource unique identifier

Query parameters
Header parameters
Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

datasetall of

Reference to the associated dataset

organizationall of

The producer organization

ownerall of

The user information

Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

datasetall of

Reference to the associated dataset

organizationall of

The producer organization

ownerall of

The user information

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/community_resources/{community}/', {
    method: 'PUT',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "filetype": "file",
      "format": "text",
      "title": "text",
      "type": "main",
      "url": "text"
    }),
});
const data = await response.json();
Response
{
  "checksum": {
    "type": "sha1",
    "value": "text"
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "filetype": "file",
  "format": "text",
  "harvest": {
    "created_at": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "latest": "text",
  "mime": "text",
  "preview_url": "text",
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "title": "text",
  "type": "main",
  "url": "text",
  "dataset": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "page": "text",
    "title": "text",
    "uri": "text"
  },
  "organization": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "badges": [
      {
        "kind": "text"
      }
    ],
    "logo": "text",
    "logo_thumbnail": "text",
    "name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "owner": {
    "class": "text",
    "id": "text",
    "avatar": "text",
    "avatar_thumbnail": "text",
    "first_name": "text",
    "last_name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  }
}

Delete a given community resource

DELETE//www.data.gouv.fr/api/1/datasets/community_resources/{community}/
Path parameters
community*string

The community resource unique identifier

Query parameters
Response

Success

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/community_resources/{community}/', {
    method: 'DELETE',
    headers: {},
});
const data = await response.json();

Update the file related to a given community resource

POST//www.data.gouv.fr/api/1/datasets/community_resources/{community}/upload/
Path parameters
community*string

The community resource unique identifier

Query parameters
Header parameters
Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

successboolean

Whether the upload succeeded or not.

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/community_resources/{community}/upload/', {
    method: 'POST',
    headers: {},
});
const data = await response.json();
Response
{
  "checksum": {
    "type": "sha1",
    "value": "text"
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "filetype": "file",
  "format": "text",
  "harvest": {
    "created_at": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "latest": "text",
  "mime": "text",
  "preview_url": "text",
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "title": "text",
  "type": "main",
  "url": "text",
  "success": true
}

List all allowed resources extensions

GET//www.data.gouv.fr/api/1/datasets/extensions/
Response

Success

Body
itemsstring
Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/extensions/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
[
  "text"
]

List all available frequencies

GET//www.data.gouv.fr/api/1/datasets/frequencies/
Header parameters
Response

Success

Body
idstring

The frequency identifier

labelstring

The frequency display name

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/frequencies/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
[
  {
    "id": "text",
    "label": "text"
  }
]

List all available licenses

GET//www.data.gouv.fr/api/1/datasets/licenses/
Header parameters
Response

Success

Body
alternate_titlesarray of string

Same alternative known titles (improve rematch)

alternate_urlsarray of string

Same alternative known URLs (improve rematch)

flagsarray of string

Some arbitry flags

id*string

The license identifier

maintainerstring

The license official maintainer

title*string

The resource title

urlstring

The license official URL

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/licenses/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
[
  {
    "alternate_titles": [
      "text"
    ],
    "alternate_urls": [
      "text"
    ],
    "flags": [
      "text"
    ],
    "id": "text",
    "maintainer": "text",
    "title": "text",
    "url": "text"
  }
]

Redirect to the latest version of a resource given its identifier

GET//www.data.gouv.fr/api/1/datasets/r/{id}
Path parameters
id*string
Query parameters
Response

Success

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/r/{id}', {
    method: 'GET',
    headers: {},
});
const data = await response.json();

List all resource types

GET//www.data.gouv.fr/api/1/datasets/resource_types/
Header parameters
Response

Success

Body
idstring

The resource type identifier

labelstring

The resource type display name

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/resource_types/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
[
  {
    "id": "text",
    "label": "text"
  }
]

List all available schemas

GET//www.data.gouv.fr/api/1/datasets/schemas/
Header parameters
Response

Success

Body
consolidation_dataset_idstring
contactstring
datapackage_descriptionstring

Only present if the schema is inside a datapackage

datapackage_namestring

Only present if the schema is inside a datapackage

datapackage_titlestring

Only present if the schema is inside a datapackage

descriptionstring
examplesarray of CatalogSchemaExample (object)
external_docstring
external_toolstring

Link to tools to create a file with this schema

homepagestring
labelsarray of string
namestring
schema_typeenum
Example: "tableschema"
tableschemadatapackagejsonschemaother
schema_urlstring

Often the link to the latest version

titlestring
versionsarray of CatalogSchemaVersion (object)
Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/schemas/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
[
  {
    "consolidation_dataset_id": "text",
    "contact": "text",
    "datapackage_description": "text",
    "datapackage_name": "text",
    "datapackage_title": "text",
    "description": "text",
    "examples": [
      {
        "path": "text",
        "title": "text"
      }
    ],
    "external_doc": "text",
    "external_tool": "text",
    "homepage": "text",
    "labels": [
      "text"
    ],
    "name": "text",
    "schema_type": "tableschema",
    "schema_url": "text",
    "title": "text",
    "versions": [
      {
        "schema_url": "text",
        "version_name": "text"
      }
    ]
  }
]

Datasets suggest endpoint using mongoDB contains

GET//www.data.gouv.fr/api/1/datasets/suggest/
Query parameters
Header parameters
Response

Success

Body
acronymstring

An optional dataset acronym

idstring

The dataset identifier

image_urlstring

The dataset (organization) logo URL

pagestring

The web page URL for this dataset

slugstring

The dataset permalink string

titlestring

The dataset title

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/suggest/?q=text', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "acronym": "text",
  "id": "text",
  "image_url": "text",
  "page": "text",
  "slug": "text",
  "title": "text"
}

Suggest file formats

GET//www.data.gouv.fr/api/1/datasets/suggest/formats/
Query parameters
Response

Success

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/suggest/formats/?q=text', {
    method: 'GET',
    headers: {},
});
const data = await response.json();

Suggest mime types

GET//www.data.gouv.fr/api/1/datasets/suggest/mime/
Query parameters
Response

Success

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/suggest/mime/?q=text', {
    method: 'GET',
    headers: {},
});
const data = await response.json();

Get a dataset given its identifier

GET//www.data.gouv.fr/api/1/datasets/{dataset}/
Path parameters
dataset*string

The dataset ID or slug

Header parameters
Response

Success

Body
acronymstring

An optional dataset acronym

archivedstring (date-time)

The archival date if archived

badgesarray of Badge (object)

The dataset badges

community_resourcesarray of all of
contact_pointall of

The dataset's contact points

created_at*string (date-time)

This date is computed between harvested creation date if any and site's internal creation date

deletedstring (date-time)

The deletion date if deleted

description*string (markdown)

The dataset description in markdown

extrasobject

Extras attributes as key-value pairs

featuredboolean

Is the dataset featured

frequency*enum

The update frequency

Example: "unknown"
unknownpunctualcontinuoushourlyfourTimesADaythreeTimesADaysemidailydailyfourTimesAWeekthreeTimesAWeeksemiweeklyweeklybiweeklythreeTimesAMonthsemimonthlymonthlybimonthlyquarterlythreeTimesAYearsemiannualannualbiennialtriennialquinquennialirregular
frequency_datestring (date-time)

Next expected update date, you will be notified once that date is reached.

harvestall of

Dataset harvest metadata attributes

idstring

The dataset identifier

internalall of

Site internal and specific object's data

last_modified*string (date-time)

The dataset last modification date

last_update*string (date-time)

The resources last modification date

licensestring

The dataset license

metricsobject

The dataset metrics

organizationall of

The producer organization

ownerall of

The user information

page*string

The dataset page URL

privateboolean

Is the dataset private to the owner or the organization

qualityobject

The dataset quality

resourcesarray of all of
schemaall of

Reference to the associated schema

slug*string

The dataset permalink string

spatialall of

The spatial coverage

tagsarray of string
temporal_coverageall of

The temporal coverage

title*string

The dataset title

uri*string

The dataset API URI

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "acronym": "text",
  "archived": "2024-10-23T15:28:25.435Z",
  "badges": [
    {
      "kind": "text"
    }
  ],
  "community_resources": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text",
      "dataset": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "page": "text",
        "title": "text",
        "uri": "text"
      },
      "organization": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "badges": [
          {
            "kind": "text"
          }
        ],
        "logo": "text",
        "logo_thumbnail": "text",
        "name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      },
      "owner": {
        "class": "text",
        "id": "text",
        "avatar": "text",
        "avatar_thumbnail": "text",
        "first_name": "text",
        "last_name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      }
    }
  ],
  "contact_point": {
    "email": "text",
    "id": "text",
    "name": "text",
    "organization": {
      "class": "text",
      "id": "text",
      "acronym": "text",
      "badges": [
        {
          "kind": "text"
        }
      ],
      "logo": "text",
      "logo_thumbnail": "text",
      "name": "text",
      "page": "text",
      "slug": "text",
      "uri": "text"
    },
    "owner": {
      "class": "text",
      "id": "text",
      "avatar": "text",
      "avatar_thumbnail": "text",
      "first_name": "text",
      "last_name": "text",
      "page": "text",
      "slug": "text",
      "uri": "text"
    }
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "deleted": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "featured": false,
  "frequency": "unknown",
  "frequency_date": "2024-10-23T15:28:25.435Z",
  "harvest": {
    "archived": "text",
    "archived_at": "2024-10-23T15:28:25.435Z",
    "backend": "text",
    "ckan_name": "text",
    "ckan_source": "text",
    "created_at": "2024-10-23T15:28:25.435Z",
    "dct_identifier": "text",
    "domain": "text",
    "last_update": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "remote_id": "text",
    "remote_url": "text",
    "source_id": "text",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "last_update": "2024-10-23T15:28:25.435Z",
  "license": "notspecified",
  "organization": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "badges": [
      {
        "kind": "text"
      }
    ],
    "logo": "text",
    "logo_thumbnail": "text",
    "name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "owner": {
    "class": "text",
    "id": "text",
    "avatar": "text",
    "avatar_thumbnail": "text",
    "first_name": "text",
    "last_name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "page": "text",
  "private": false,
  "resources": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text"
    }
  ],
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "slug": "text",
  "spatial": {
    "geom": {
      "coordinates": [],
      "type": "Point"
    },
    "granularity": "other",
    "zones": [
      "text"
    ]
  },
  "tags": [
    "text"
  ],
  "temporal_coverage": {
    "end": "2024-10-23T15:28:25.435Z",
    "start": "2024-10-23T15:28:25.435Z"
  },
  "title": "text",
  "uri": "text"
}

Update a dataset given its identifier

PUT//www.data.gouv.fr/api/1/datasets/{dataset}/
Path parameters
dataset*string

The dataset ID or slug

Header parameters
Body
acronymstring

An optional dataset acronym

archivedstring (date-time)

The archival date if archived

badgesarray of Badge (object)

The dataset badges

community_resourcesarray of all of
contact_pointall of

The dataset's contact points

created_at*string (date-time)

This date is computed between harvested creation date if any and site's internal creation date

deletedstring (date-time)

The deletion date if deleted

description*string (markdown)

The dataset description in markdown

extrasobject

Extras attributes as key-value pairs

featuredboolean

Is the dataset featured

frequency*enum

The update frequency

Example: "unknown"
unknownpunctualcontinuoushourlyfourTimesADaythreeTimesADaysemidailydailyfourTimesAWeekthreeTimesAWeeksemiweeklyweeklybiweeklythreeTimesAMonthsemimonthlymonthlybimonthlyquarterlythreeTimesAYearsemiannualannualbiennialtriennialquinquennialirregular
frequency_datestring (date-time)

Next expected update date, you will be notified once that date is reached.

harvestall of

Dataset harvest metadata attributes

idstring

The dataset identifier

internalall of

Site internal and specific object's data

last_modified*string (date-time)

The dataset last modification date

last_update*string (date-time)

The resources last modification date

licensestring

The dataset license

metricsobject

The dataset metrics

organizationall of

The producer organization

ownerall of

The user information

page*string

The dataset page URL

privateboolean

Is the dataset private to the owner or the organization

qualityobject

The dataset quality

resourcesarray of all of
schemaall of

Reference to the associated schema

slug*string

The dataset permalink string

spatialall of

The spatial coverage

tagsarray of string
temporal_coverageall of

The temporal coverage

title*string

The dataset title

uri*string

The dataset API URI

Response

Success

Body
acronymstring

An optional dataset acronym

archivedstring (date-time)

The archival date if archived

badgesarray of Badge (object)

The dataset badges

community_resourcesarray of all of
contact_pointall of

The dataset's contact points

created_at*string (date-time)

This date is computed between harvested creation date if any and site's internal creation date

deletedstring (date-time)

The deletion date if deleted

description*string (markdown)

The dataset description in markdown

extrasobject

Extras attributes as key-value pairs

featuredboolean

Is the dataset featured

frequency*enum

The update frequency

Example: "unknown"
unknownpunctualcontinuoushourlyfourTimesADaythreeTimesADaysemidailydailyfourTimesAWeekthreeTimesAWeeksemiweeklyweeklybiweeklythreeTimesAMonthsemimonthlymonthlybimonthlyquarterlythreeTimesAYearsemiannualannualbiennialtriennialquinquennialirregular
frequency_datestring (date-time)

Next expected update date, you will be notified once that date is reached.

harvestall of

Dataset harvest metadata attributes

idstring

The dataset identifier

internalall of

Site internal and specific object's data

last_modified*string (date-time)

The dataset last modification date

last_update*string (date-time)

The resources last modification date

licensestring

The dataset license

metricsobject

The dataset metrics

organizationall of

The producer organization

ownerall of

The user information

page*string

The dataset page URL

privateboolean

Is the dataset private to the owner or the organization

qualityobject

The dataset quality

resourcesarray of all of
schemaall of

Reference to the associated schema

slug*string

The dataset permalink string

spatialall of

The spatial coverage

tagsarray of string
temporal_coverageall of

The temporal coverage

title*string

The dataset title

uri*string

The dataset API URI

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/', {
    method: 'PUT',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "frequency": "unknown",
      "last_modified": "2024-10-23T15:28:25.435Z",
      "last_update": "2024-10-23T15:28:25.435Z",
      "page": "text",
      "slug": "text",
      "title": "text",
      "uri": "text"
    }),
});
const data = await response.json();
Response
{
  "acronym": "text",
  "archived": "2024-10-23T15:28:25.435Z",
  "badges": [
    {
      "kind": "text"
    }
  ],
  "community_resources": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text",
      "dataset": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "page": "text",
        "title": "text",
        "uri": "text"
      },
      "organization": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "badges": [
          {
            "kind": "text"
          }
        ],
        "logo": "text",
        "logo_thumbnail": "text",
        "name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      },
      "owner": {
        "class": "text",
        "id": "text",
        "avatar": "text",
        "avatar_thumbnail": "text",
        "first_name": "text",
        "last_name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      }
    }
  ],
  "contact_point": {
    "email": "text",
    "id": "text",
    "name": "text",
    "organization": {
      "class": "text",
      "id": "text",
      "acronym": "text",
      "badges": [
        {
          "kind": "text"
        }
      ],
      "logo": "text",
      "logo_thumbnail": "text",
      "name": "text",
      "page": "text",
      "slug": "text",
      "uri": "text"
    },
    "owner": {
      "class": "text",
      "id": "text",
      "avatar": "text",
      "avatar_thumbnail": "text",
      "first_name": "text",
      "last_name": "text",
      "page": "text",
      "slug": "text",
      "uri": "text"
    }
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "deleted": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "featured": false,
  "frequency": "unknown",
  "frequency_date": "2024-10-23T15:28:25.435Z",
  "harvest": {
    "archived": "text",
    "archived_at": "2024-10-23T15:28:25.435Z",
    "backend": "text",
    "ckan_name": "text",
    "ckan_source": "text",
    "created_at": "2024-10-23T15:28:25.435Z",
    "dct_identifier": "text",
    "domain": "text",
    "last_update": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "remote_id": "text",
    "remote_url": "text",
    "source_id": "text",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "last_update": "2024-10-23T15:28:25.435Z",
  "license": "notspecified",
  "organization": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "badges": [
      {
        "kind": "text"
      }
    ],
    "logo": "text",
    "logo_thumbnail": "text",
    "name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "owner": {
    "class": "text",
    "id": "text",
    "avatar": "text",
    "avatar_thumbnail": "text",
    "first_name": "text",
    "last_name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "page": "text",
  "private": false,
  "resources": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text"
    }
  ],
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "slug": "text",
  "spatial": {
    "geom": {
      "coordinates": [],
      "type": "Point"
    },
    "granularity": "other",
    "zones": [
      "text"
    ]
  },
  "tags": [
    "text"
  ],
  "temporal_coverage": {
    "end": "2024-10-23T15:28:25.435Z",
    "start": "2024-10-23T15:28:25.435Z"
  },
  "title": "text",
  "uri": "text"
}

Delete a dataset given its identifier

DELETE//www.data.gouv.fr/api/1/datasets/{dataset}/
Path parameters
dataset*string

The dataset ID or slug

Response

Dataset deleted

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/', {
    method: 'DELETE',
    headers: {},
});
const data = await response.json();

Create a new badge for a given dataset

POST//www.data.gouv.fr/api/1/datasets/{dataset}/badges/
Path parameters
dataset*string

The dataset ID or slug

Header parameters
Body
kind*string

Kind of badge (certified, etc), specific to each model

Response

Success

Body
kind*string

Kind of badge (certified, etc), specific to each model

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/badges/', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "kind": "text"
    }),
});
const data = await response.json();
Response
{
  "kind": "text"
}

Delete a badge for a given dataset

DELETE//www.data.gouv.fr/api/1/datasets/{dataset}/badges/{badge_kind}/
Path parameters
badge_kind*string
dataset*string

The dataset ID or slug

Response

Success

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/badges/{badge_kind}/', {
    method: 'DELETE',
    headers: {},
});
const data = await response.json();
POST//www.data.gouv.fr/api/1/datasets/{dataset}/featured/
Path parameters
dataset*string

The dataset ID or slug

Header parameters
Response

Success

Body
acronymstring

An optional dataset acronym

archivedstring (date-time)

The archival date if archived

badgesarray of Badge (object)

The dataset badges

community_resourcesarray of all of
contact_pointall of

The dataset's contact points

created_at*string (date-time)

This date is computed between harvested creation date if any and site's internal creation date

deletedstring (date-time)

The deletion date if deleted

description*string (markdown)

The dataset description in markdown

extrasobject

Extras attributes as key-value pairs

featuredboolean

Is the dataset featured

frequency*enum

The update frequency

Example: "unknown"
unknownpunctualcontinuoushourlyfourTimesADaythreeTimesADaysemidailydailyfourTimesAWeekthreeTimesAWeeksemiweeklyweeklybiweeklythreeTimesAMonthsemimonthlymonthlybimonthlyquarterlythreeTimesAYearsemiannualannualbiennialtriennialquinquennialirregular
frequency_datestring (date-time)

Next expected update date, you will be notified once that date is reached.

harvestall of

Dataset harvest metadata attributes

idstring

The dataset identifier

internalall of

Site internal and specific object's data

last_modified*string (date-time)

The dataset last modification date

last_update*string (date-time)

The resources last modification date

licensestring

The dataset license

metricsobject

The dataset metrics

organizationall of

The producer organization

ownerall of

The user information

page*string

The dataset page URL

privateboolean

Is the dataset private to the owner or the organization

qualityobject

The dataset quality

resourcesarray of all of
schemaall of

Reference to the associated schema

slug*string

The dataset permalink string

spatialall of

The spatial coverage

tagsarray of string
temporal_coverageall of

The temporal coverage

title*string

The dataset title

uri*string

The dataset API URI

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/featured/', {
    method: 'POST',
    headers: {},
});
const data = await response.json();
Response
{
  "acronym": "text",
  "archived": "2024-10-23T15:28:25.435Z",
  "badges": [
    {
      "kind": "text"
    }
  ],
  "community_resources": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text",
      "dataset": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "page": "text",
        "title": "text",
        "uri": "text"
      },
      "organization": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "badges": [
          {
            "kind": "text"
          }
        ],
        "logo": "text",
        "logo_thumbnail": "text",
        "name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      },
      "owner": {
        "class": "text",
        "id": "text",
        "avatar": "text",
        "avatar_thumbnail": "text",
        "first_name": "text",
        "last_name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      }
    }
  ],
  "contact_point": {
    "email": "text",
    "id": "text",
    "name": "text",
    "organization": {
      "class": "text",
      "id": "text",
      "acronym": "text",
      "badges": [
        {
          "kind": "text"
        }
      ],
      "logo": "text",
      "logo_thumbnail": "text",
      "name": "text",
      "page": "text",
      "slug": "text",
      "uri": "text"
    },
    "owner": {
      "class": "text",
      "id": "text",
      "avatar": "text",
      "avatar_thumbnail": "text",
      "first_name": "text",
      "last_name": "text",
      "page": "text",
      "slug": "text",
      "uri": "text"
    }
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "deleted": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "featured": false,
  "frequency": "unknown",
  "frequency_date": "2024-10-23T15:28:25.435Z",
  "harvest": {
    "archived": "text",
    "archived_at": "2024-10-23T15:28:25.435Z",
    "backend": "text",
    "ckan_name": "text",
    "ckan_source": "text",
    "created_at": "2024-10-23T15:28:25.435Z",
    "dct_identifier": "text",
    "domain": "text",
    "last_update": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "remote_id": "text",
    "remote_url": "text",
    "source_id": "text",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "last_update": "2024-10-23T15:28:25.435Z",
  "license": "notspecified",
  "organization": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "badges": [
      {
        "kind": "text"
      }
    ],
    "logo": "text",
    "logo_thumbnail": "text",
    "name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "owner": {
    "class": "text",
    "id": "text",
    "avatar": "text",
    "avatar_thumbnail": "text",
    "first_name": "text",
    "last_name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "page": "text",
  "private": false,
  "resources": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text"
    }
  ],
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "slug": "text",
  "spatial": {
    "geom": {
      "coordinates": [],
      "type": "Point"
    },
    "granularity": "other",
    "zones": [
      "text"
    ]
  },
  "tags": [
    "text"
  ],
  "temporal_coverage": {
    "end": "2024-10-23T15:28:25.435Z",
    "start": "2024-10-23T15:28:25.435Z"
  },
  "title": "text",
  "uri": "text"
}
DELETE//www.data.gouv.fr/api/1/datasets/{dataset}/featured/
Path parameters
dataset*string

The dataset ID or slug

Header parameters
Response

Success

Body
acronymstring

An optional dataset acronym

archivedstring (date-time)

The archival date if archived

badgesarray of Badge (object)

The dataset badges

community_resourcesarray of all of
contact_pointall of

The dataset's contact points

created_at*string (date-time)

This date is computed between harvested creation date if any and site's internal creation date

deletedstring (date-time)

The deletion date if deleted

description*string (markdown)

The dataset description in markdown

extrasobject

Extras attributes as key-value pairs

featuredboolean

Is the dataset featured

frequency*enum

The update frequency

Example: "unknown"
unknownpunctualcontinuoushourlyfourTimesADaythreeTimesADaysemidailydailyfourTimesAWeekthreeTimesAWeeksemiweeklyweeklybiweeklythreeTimesAMonthsemimonthlymonthlybimonthlyquarterlythreeTimesAYearsemiannualannualbiennialtriennialquinquennialirregular
frequency_datestring (date-time)

Next expected update date, you will be notified once that date is reached.

harvestall of

Dataset harvest metadata attributes

idstring

The dataset identifier

internalall of

Site internal and specific object's data

last_modified*string (date-time)

The dataset last modification date

last_update*string (date-time)

The resources last modification date

licensestring

The dataset license

metricsobject

The dataset metrics

organizationall of

The producer organization

ownerall of

The user information

page*string

The dataset page URL

privateboolean

Is the dataset private to the owner or the organization

qualityobject

The dataset quality

resourcesarray of all of
schemaall of

Reference to the associated schema

slug*string

The dataset permalink string

spatialall of

The spatial coverage

tagsarray of string
temporal_coverageall of

The temporal coverage

title*string

The dataset title

uri*string

The dataset API URI

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/featured/', {
    method: 'DELETE',
    headers: {},
});
const data = await response.json();
Response
{
  "acronym": "text",
  "archived": "2024-10-23T15:28:25.435Z",
  "badges": [
    {
      "kind": "text"
    }
  ],
  "community_resources": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text",
      "dataset": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "page": "text",
        "title": "text",
        "uri": "text"
      },
      "organization": {
        "class": "text",
        "id": "text",
        "acronym": "text",
        "badges": [
          {
            "kind": "text"
          }
        ],
        "logo": "text",
        "logo_thumbnail": "text",
        "name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      },
      "owner": {
        "class": "text",
        "id": "text",
        "avatar": "text",
        "avatar_thumbnail": "text",
        "first_name": "text",
        "last_name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      }
    }
  ],
  "contact_point": {
    "email": "text",
    "id": "text",
    "name": "text",
    "organization": {
      "class": "text",
      "id": "text",
      "acronym": "text",
      "badges": [
        {
          "kind": "text"
        }
      ],
      "logo": "text",
      "logo_thumbnail": "text",
      "name": "text",
      "page": "text",
      "slug": "text",
      "uri": "text"
    },
    "owner": {
      "class": "text",
      "id": "text",
      "avatar": "text",
      "avatar_thumbnail": "text",
      "first_name": "text",
      "last_name": "text",
      "page": "text",
      "slug": "text",
      "uri": "text"
    }
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "deleted": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "featured": false,
  "frequency": "unknown",
  "frequency_date": "2024-10-23T15:28:25.435Z",
  "harvest": {
    "archived": "text",
    "archived_at": "2024-10-23T15:28:25.435Z",
    "backend": "text",
    "ckan_name": "text",
    "ckan_source": "text",
    "created_at": "2024-10-23T15:28:25.435Z",
    "dct_identifier": "text",
    "domain": "text",
    "last_update": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "remote_id": "text",
    "remote_url": "text",
    "source_id": "text",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "last_update": "2024-10-23T15:28:25.435Z",
  "license": "notspecified",
  "organization": {
    "class": "text",
    "id": "text",
    "acronym": "text",
    "badges": [
      {
        "kind": "text"
      }
    ],
    "logo": "text",
    "logo_thumbnail": "text",
    "name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "owner": {
    "class": "text",
    "id": "text",
    "avatar": "text",
    "avatar_thumbnail": "text",
    "first_name": "text",
    "last_name": "text",
    "page": "text",
    "slug": "text",
    "uri": "text"
  },
  "page": "text",
  "private": false,
  "resources": [
    {
      "checksum": {
        "type": "sha1",
        "value": "text"
      },
      "created_at": "2024-10-23T15:28:25.435Z",
      "description": "text",
      "filetype": "file",
      "format": "text",
      "harvest": {
        "created_at": "2024-10-23T15:28:25.435Z",
        "modified_at": "2024-10-23T15:28:25.435Z",
        "uri": "text"
      },
      "id": "text",
      "internal": {
        "created_at_internal": "2024-10-23T15:28:25.435Z",
        "last_modified_internal": "2024-10-23T15:28:25.435Z"
      },
      "last_modified": "2024-10-23T15:28:25.435Z",
      "latest": "text",
      "mime": "text",
      "preview_url": "text",
      "schema": {
        "name": "text",
        "url": "text",
        "version": "text"
      },
      "title": "text",
      "type": "main",
      "url": "text"
    }
  ],
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "slug": "text",
  "spatial": {
    "geom": {
      "coordinates": [],
      "type": "Point"
    },
    "granularity": "other",
    "zones": [
      "text"
    ]
  },
  "tags": [
    "text"
  ],
  "temporal_coverage": {
    "end": "2024-10-23T15:28:25.435Z",
    "start": "2024-10-23T15:28:25.435Z"
  },
  "title": "text",
  "uri": "text"
}

GET//www.data.gouv.fr/api/1/datasets/{dataset}/rdf
Path parameters
dataset*string

The dataset ID or slug

Response

Dataset not found

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/rdf', {
    method: 'GET',
    headers: {},
});
const data = await response.json();

GET//www.data.gouv.fr/api/1/datasets/{dataset}/rdf.{format}
Path parameters
dataset*string

The dataset ID or slug

format*string
Response

Dataset not found

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/rdf.{format}', {
    method: 'GET',
    headers: {},
});
const data = await response.json();

Create a new resource for a given dataset

POST//www.data.gouv.fr/api/1/datasets/{dataset}/resources/
Path parameters
dataset*string

The dataset ID or slug

Header parameters
Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/resources/', {
    method: 'POST',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "filetype": "file",
      "format": "text",
      "title": "text",
      "type": "main",
      "url": "text"
    }),
});
const data = await response.json();
Response
{
  "checksum": {
    "type": "sha1",
    "value": "text"
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "filetype": "file",
  "format": "text",
  "harvest": {
    "created_at": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "latest": "text",
  "mime": "text",
  "preview_url": "text",
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "title": "text",
  "type": "main",
  "url": "text"
}

Reorder resources

PUT//www.data.gouv.fr/api/1/datasets/{dataset}/resources/
Path parameters
dataset*string

The dataset ID or slug

Header parameters
Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/resources/', {
    method: 'PUT',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify([
      {
        "filetype": "file",
        "format": "text",
        "title": "text",
        "type": "main",
        "url": "text"
      }
    ]),
});
const data = await response.json();
Response
[
  {
    "checksum": {
      "type": "sha1",
      "value": "text"
    },
    "created_at": "2024-10-23T15:28:25.435Z",
    "description": "text",
    "filetype": "file",
    "format": "text",
    "harvest": {
      "created_at": "2024-10-23T15:28:25.435Z",
      "modified_at": "2024-10-23T15:28:25.435Z",
      "uri": "text"
    },
    "id": "text",
    "internal": {
      "created_at_internal": "2024-10-23T15:28:25.435Z",
      "last_modified_internal": "2024-10-23T15:28:25.435Z"
    },
    "last_modified": "2024-10-23T15:28:25.435Z",
    "latest": "text",
    "mime": "text",
    "preview_url": "text",
    "schema": {
      "name": "text",
      "url": "text",
      "version": "text"
    },
    "title": "text",
    "type": "main",
    "url": "text"
  }
]

Get a resource given its identifier

GET//www.data.gouv.fr/api/1/datasets/{dataset}/resources/{rid}/
Path parameters
rid*string

The resource unique identifier

dataset*string

The dataset ID or slug

Header parameters
Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/resources/{rid}/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "checksum": {
    "type": "sha1",
    "value": "text"
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "filetype": "file",
  "format": "text",
  "harvest": {
    "created_at": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "latest": "text",
  "mime": "text",
  "preview_url": "text",
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "title": "text",
  "type": "main",
  "url": "text"
}

Update a given resource on a given dataset

PUT//www.data.gouv.fr/api/1/datasets/{dataset}/resources/{rid}/
Path parameters
rid*string

The resource unique identifier

dataset*string

The dataset ID or slug

Header parameters
Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/resources/{rid}/', {
    method: 'PUT',
    headers: {
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      "filetype": "file",
      "format": "text",
      "title": "text",
      "type": "main",
      "url": "text"
    }),
});
const data = await response.json();
Response
{
  "checksum": {
    "type": "sha1",
    "value": "text"
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "filetype": "file",
  "format": "text",
  "harvest": {
    "created_at": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "latest": "text",
  "mime": "text",
  "preview_url": "text",
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "title": "text",
  "type": "main",
  "url": "text"
}

Delete a given resource on a given dataset

DELETE//www.data.gouv.fr/api/1/datasets/{dataset}/resources/{rid}/
Path parameters
rid*string

The resource unique identifier

dataset*string

The dataset ID or slug

Response

Success

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/resources/{rid}/', {
    method: 'DELETE',
    headers: {},
});
const data = await response.json();

Checks that a resource's URL exists and returns metadata

GET//www.data.gouv.fr/api/1/datasets/{dataset}/resources/{rid}/check/
Path parameters
rid*string

The resource unique identifier

dataset*string

The dataset ID or slug

Response

Success

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/resources/{rid}/check/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();

Upload a file related to a given resource on a given dataset

POST//www.data.gouv.fr/api/1/datasets/{dataset}/resources/{rid}/upload/
Path parameters
rid*string

The resource unique identifier

dataset*string

The dataset ID or slug

Header parameters
Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

successboolean

Whether the upload succeeded or not.

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/resources/{rid}/upload/', {
    method: 'POST',
    headers: {},
});
const data = await response.json();
Response
{
  "checksum": {
    "type": "sha1",
    "value": "text"
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "filetype": "file",
  "format": "text",
  "harvest": {
    "created_at": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "latest": "text",
  "mime": "text",
  "preview_url": "text",
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "title": "text",
  "type": "main",
  "url": "text",
  "success": true
}

Upload a new dataset resource

POST//www.data.gouv.fr/api/1/datasets/{dataset}/upload/
Path parameters
dataset*string

The dataset ID or slug

Header parameters
Body
filestring (binary)
uuidstring
filenamestring
partindexinteger
partbyteoffsetinteger
totalpartsinteger
chunksizeinteger
Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

successboolean

Whether the upload succeeded or not.

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/upload/', {
    method: 'POST',
    headers: {
      "Content-Type": "multipart/form-data"
    },
    body: JSON.stringify({}),
});
const data = await response.json();
Response
{
  "checksum": {
    "type": "sha1",
    "value": "text"
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "filetype": "file",
  "format": "text",
  "harvest": {
    "created_at": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "latest": "text",
  "mime": "text",
  "preview_url": "text",
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "title": "text",
  "type": "main",
  "url": "text",
  "success": true
}

Upload a new community resource

POST//www.data.gouv.fr/api/1/datasets/{dataset}/upload/community/
Path parameters
dataset*string

The dataset ID or slug

Header parameters
Body
filestring (binary)
uuidstring
filenamestring
partindexinteger
partbyteoffsetinteger
totalpartsinteger
chunksizeinteger
Response

Success

Body
checksumall of

A checksum to validate file validity

created_atstring (date-time)

The resource creation date

descriptionstring (markdown)

The resource markdown description

extrasobject

Extra attributes as key-value pairs

filesizeinteger

The resource file size in bytes

filetype*enum

Whether the resource is an uploaded file, a remote file or an API

Example: "file"
fileremote
format*string

The resource format

harvestall of

Harvest attributes metadata information

idstring

The resource unique ID

internalall of

Site internal and specific object's data

last_modifiedstring (date-time)

The resource last modification date

lateststring

The permanent URL redirecting to the latest version of the resource. When the resource data is updated, the URL will change, the latest URL won't.

metricsobject

The resource metrics

mimestring

The resource mime type

preview_urlstring

An optional preview URL to be loaded as a standalone page (ie. iframe or new page)

schemaall of

Reference to the associated schema

title*string

The resource title

type*enum

Resource type (documentation, API...)

Example: "main"
maindocumentationupdateapicodeother
url*string

The resource URL

successboolean

Whether the upload succeeded or not.

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{dataset}/upload/community/', {
    method: 'POST',
    headers: {
      "Content-Type": "multipart/form-data"
    },
    body: JSON.stringify({}),
});
const data = await response.json();
Response
{
  "checksum": {
    "type": "sha1",
    "value": "text"
  },
  "created_at": "2024-10-23T15:28:25.435Z",
  "description": "text",
  "filetype": "file",
  "format": "text",
  "harvest": {
    "created_at": "2024-10-23T15:28:25.435Z",
    "modified_at": "2024-10-23T15:28:25.435Z",
    "uri": "text"
  },
  "id": "text",
  "internal": {
    "created_at_internal": "2024-10-23T15:28:25.435Z",
    "last_modified_internal": "2024-10-23T15:28:25.435Z"
  },
  "last_modified": "2024-10-23T15:28:25.435Z",
  "latest": "text",
  "mime": "text",
  "preview_url": "text",
  "schema": {
    "name": "text",
    "url": "text",
    "version": "text"
  },
  "title": "text",
  "type": "main",
  "url": "text",
  "success": true
}

List all followers for a given object

GET//www.data.gouv.fr/api/1/datasets/{id}/followers/
Path parameters
id*string
Query parameters
Header parameters
Response

Success

Body
dataarray of Follow (object)

The page data

next_pagestring

The next page URL if exists

page*integer

The current page

page_size*integer

The page size used for pagination

previous_pagestring

The previous page URL if exists

total*integer

The total paginated items

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{id}/followers/', {
    method: 'GET',
    headers: {},
});
const data = await response.json();
Response
{
  "data": [
    {
      "follower": {
        "class": "text",
        "id": "text",
        "avatar": "text",
        "avatar_thumbnail": "text",
        "first_name": "text",
        "last_name": "text",
        "page": "text",
        "slug": "text",
        "uri": "text"
      },
      "id": "text",
      "since": "2024-10-23T15:28:25.435Z"
    }
  ],
  "next_page": "text",
  "previous_page": "text"
}

Follow an object given its ID

Returns the number of followers left after the operation

POST//www.data.gouv.fr/api/1/datasets/{id}/followers/
Path parameters
id*string
Response

Success

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{id}/followers/', {
    method: 'POST',
    headers: {},
});
const data = await response.json();

Unfollow an object given its ID

Returns the number of followers left after the operation

DELETE//www.data.gouv.fr/api/1/datasets/{id}/followers/
Path parameters
id*string
Response

Success

Request
const response = await fetch('//www.data.gouv.fr/api/1/datasets/{id}/followers/', {
    method: 'DELETE',
    headers: {},
});
const data = await response.json();

Dernière mise à jour

Revision created

Update faq-cadastre.md