OpenAPI Specification
openapi: 3.0.3
info:
title: Zenodo REST Access Communities API
description: 'REST API for Zenodo, the free open research data repository operated by CERN and built on InvenioRDM. Provides programmatic access to deposits (draft records), published records, file management, communities, vocabularies, OAI-PMH sets, requests, users, groups, statistics, and audit logs. Every published record receives a DOI for persistent citation. Authenticate with a personal access token passed as a Bearer token.
'
version: 12.0.0
contact:
name: Zenodo Developer Documentation
url: https://developers.zenodo.org/
license:
name: MIT License
url: https://opensource.org/licenses/MIT
x-upstream-spec: https://github.com/inveniosoftware/invenio-openapi
servers:
- url: https://zenodo.org
description: Zenodo production instance
- url: https://sandbox.zenodo.org
description: Zenodo sandbox (testing)
security:
- BearerAuth: []
tags:
- name: Communities
description: Community management endpoints
paths:
/api/communities:
post:
summary: Create a community
tags:
- Communities
operationId: createACommunity
requestBody:
required: true
content:
application/json:
schema:
type: object
example:
access:
visibility: public
member_policy: open
record_policy: open
slug: my-community
metadata:
title: My Community
description: A research community
type:
id: project
website: https://example.org/
responses:
'201':
$ref: '#/components/responses/Created'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'500':
$ref: '#/components/responses/InternalServerError'
security:
- BearerAuth: []
get:
summary: Search communities
tags:
- Communities
operationId: searchCommunities
parameters:
- name: q
in: query
required: false
schema:
type: string
- name: sort
in: query
required: false
schema:
type: string
example: updated-asc
- name: size
in: query
required: false
schema:
type: string
- name: page
in: query
required: false
schema:
type: string
- name: type
in: query
required: false
schema:
type: string
description: 'Community type: organization, event, topic, project'
responses:
'200':
$ref: '#/components/responses/Success'
'400':
$ref: '#/components/responses/BadRequest'
'500':
$ref: '#/components/responses/InternalServerError'
/api/communities/{communityId}:
get:
summary: Get a community
tags:
- Communities
operationId: getACommunity
parameters:
- name: communityId
in: path
required: true
schema:
type: string
responses:
'200':
$ref: '#/components/responses/Success'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
security:
- BearerAuth: []
put:
summary: Update a community
tags:
- Communities
operationId: updateACommunity
parameters:
- name: communityId
in: path
required: true
schema:
type: string
requestBody:
required: true
content:
application/json:
schema:
type: object
responses:
'200':
$ref: '#/components/responses/Success'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
security:
- BearerAuth: []
delete:
summary: Delete a community
tags:
- Communities
operationId: deleteCommunity
parameters:
- name: communityId
in: path
required: true
schema:
type: string
responses:
'200':
$ref: '#/components/responses/Success'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
security:
- BearerAuth: []
/api/communities/{communityId}/records:
get:
summary: Get records in a community
tags:
- Communities
operationId: getCommunityRecords
parameters:
- name: communityId
in: path
required: true
schema:
type: string
- name: q
in: query
required: false
schema:
type: string
responses:
'200':
$ref: '#/components/responses/Success'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
security:
- BearerAuth: []
/api/communities/{communityId}/rename:
post:
summary: Rename a community
tags:
- Communities
operationId: renameACommunity
parameters:
- name: communityId
in: path
required: true
schema:
type: string
requestBody:
required: true
content:
application/json:
schema:
type: object
example:
slug: new-slug
responses:
'201':
$ref: '#/components/responses/Created'
'400':
$ref: '#/components/responses/BadRequest'
'401':
$ref: '#/components/responses/Unauthorized'
'403':
$ref: '#/components/responses/Forbidden'
'404':
$ref: '#/components/responses/NotFound'
'500':
$ref: '#/components/responses/InternalServerError'
security:
- BearerAuth: []
components:
responses:
Created:
description: Resource created successfully
content:
application/json:
schema:
type: object
Success:
description: Successful response
content:
application/json:
schema:
type: object
Unauthorized:
description: Unauthorized - authentication required
BadRequest:
description: Bad request - invalid input parameters
NotFound:
description: Not found - resource does not exist
Forbidden:
description: Forbidden - insufficient permissions
InternalServerError:
description: Internal server error
securitySchemes:
BearerAuth:
type: http
scheme: bearer
description: Personal access token issued from the Zenodo account settings