PlanRadar Project Reports Templates API

Manage project report templates

OpenAPI Specification

planradar-project-reports-templates-api-openapi.yml Raw ↑
swagger: '2.0'
info:
  title: PlanRadar's API Documentation Approval Requests V2 Project Reports Templates API
  version: '2.0'
  description: "Welcome to PlanRadar's API documentation, here you can find all the details about our APIs as well as test them online.<br />\n        <h5>Rate Limits</h5>30 requests per minute per account, aggregated across all tokens.<br />\n        If the threshold is exceeded, a 5-minute cooldown is applied to the account, aggregated across all tokens.<br />\n        During the cooldown period, further requests may be rejected until the cooldown ends.<br />\n        In rare cases, an endpoint may have a different rate limit than the default. When that happens, the differing limit will be explicitly stated in the API documentation for that endpoint.<br />\n        <h5>Access Key</h5>In order to be able to access any API you have to create an access token.Therefore you have to follow these steps:-\n        <ul>\n          <li>Go to your profile page and click on Personal Access Tokens on the left side bar</li><li>Click on the 'Create Access Token' top right button in order to create a new access token.</li><li>Copy the created token and paste it into the field that pops up when you click on the 'Authorize' button </li><li>Note: you can copy the token only once.</li><li>Now you can easily access any API</li>\n        </ul>\n        <h5>V2 APIs</h5>We are currently working on upgrading all our APIs to v2, and we recommend that you use v2 APIs if it is available.\n        <p>V2 APIs are faster, robust and more flexible than v1 APIs</p>"
basePath: /
schemes:
- https
- http
consumes:
- application/json
produces:
- application/json
tags:
- name: Project Reports Templates
  description: Manage project report templates
paths:
  /api/v1/{customer_id}/site_report_templates:
    post:
      summary: Creates report template
      tags:
      - Project Reports Templates
      description: 'This API is used for creating a report template '
      produces:
      - application/json
      security:
      - apiKey: []
      parameters:
      - name: customer_id
        in: path
        type: string
        required: true
      - name: data[attributes][uuid]
        in: formData
        type: string
      - name: data[attributes][file]
        in: formData
        type: file
        description: is required - file must contain form fields
      - name: data[attributes][title]
        in: formData
        type: string
        description: is required
      - name: data[attributes][visibility]
        in: formData
        type: string
        description: 'allowed values: "only_author", "all_users", " only_inhouse"'
      - name: data[attributes][updated_at]
        in: formData
        type: string
        description: is a Unix timestamp
      - name: data[attributes][created_at]
        in: formData
        type: string
        description: is a Unix timestamp
      - name: data[attributes][support-image-upload]
        in: formData
        type: boolean
      - name: data[attributes][allowed-image-size]
        in: formData
        type: string
        description: 'allowed values: "small", "medium", "large"'
      - name: data[attributes][allowed-image-description]
        in: formData
        type: string
        description: 'allowed values: "date_time_caption", "date_caption", "caption"'
      responses:
        '406':
          description: Unsupported Accept Header
    get:
      summary: Returns all report templates
      tags:
      - Project Reports Templates
      description: 'This API returns all report templates of the logged in customer. Without any extra parameters it will return the first 100 report templates ordered by ascending id. Extra parameters can be added to sort the results. The sort is always ascending unless the field name is prefixed with a minus (U+002D HYPHEN-MINUS, "-") i.e. `-id` or `id`.<br /><b>Report Template Sorting:</b> Report Templates can be sorted by id: sequential-id, name: title, author: users-id, creation date: created-at or update date: updated-at.<br /><b>Example#1: </b> `/site_report_templates?sort=-sequential-id`<br /><b>Example#2: </b> `/site_report_templates?sort=created-at`<br />'
      produces:
      - application/json
      security:
      - apiKey: []
      parameters:
      - name: customer_id
        in: path
        type: string
        required: true
      - name: project_id
        in: path
        type: string
        required: true
      - name: search
        in: query
        type: string
        description: search keyword based on which report templates are returned
      - name: sort
        in: query
        type: string
      - name: page
        in: query
        type: integer
        description: sets the number of pages for the returned report templates
      - name: pagesize
        in: query
        type: integer
        description: sets the number of report templates that should be returned per page <br/>Maximum is 500, default is 100
      responses:
        '406':
          description: Unsupported Accept Header
  /api/v1/{customer_id}/site_report_templates/{uuid}:
    put:
      summary: Updates specific report template
      tags:
      - Project Reports Templates
      description: This API is used for updating a specific report template based on its uuid.
      produces:
      - application/json
      security:
      - apiKey: []
      parameters:
      - name: customer_id
        in: path
        type: string
        required: true
      - name: uuid
        in: path
        type: string
        description: unique identifier of the report template
        required: true
      - name: data[attributes][file]
        in: formData
        type: file
        description: file must contain form fields
      - name: data[attributes][title]
        in: formData
        type: string
      - name: data[attributes][visibility]
        in: formData
        type: string
        description: 'allowed values: "only_author", "all_users", " only_inhouse"'
      responses:
        '406':
          description: Unsupported Accept Header
    get:
      summary: Returns specific report template
      tags:
      - Project Reports Templates
      description: This API returns a specific report template based on its uuid.
      produces:
      - application/json
      security:
      - apiKey: []
      parameters:
      - name: customer_id
        in: path
        type: string
        required: true
      - name: uuid
        in: path
        type: string
        description: unique identifier of the report template
        required: true
      responses:
        '406':
          description: Unsupported Accept Header
    delete:
      summary: Deletes specific report template
      tags:
      - Project Reports Templates
      description: This API is used for deleting a specific report template based on its uuid.
      produces:
      - application/json
      security:
      - apiKey: []
      parameters:
      - name: customer_id
        in: path
        type: string
        required: true
      - name: uuid
        in: path
        type: string
        description: unique identifier of the report template
        required: true
      responses:
        '406':
          description: Unsupported Accept Header
  /api/v1/{customer_id}/site_report_templates/{uuid}/clone:
    get:
      summary: Clones specific report template
      tags:
      - Project Reports Templates
      description: This API is used for cloning a specific report template based on its uuid.
      produces:
      - application/json
      security:
      - apiKey: []
      parameters:
      - name: customer_id
        in: path
        type: string
        required: true
      - name: uuid
        in: path
        type: string
        description: unique identifier of the report template that should be cloned
        required: true
      responses:
        '406':
          description: Unsupported Accept Header
securityDefinitions:
  apiKey:
    type: apiKey
    name: X-PlanRadar-API-Key
    in: header
externalDocs:
  description: Find out more about our development portal
  url: https://www.planradar.com/knowledge-base-overview/