summaryrefslogtreecommitdiff
path: root/lib/api/entities/project_integration_basic.rb
blob: aa0ad158b83a2f73f86bac69f880f5c868dd8912 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# frozen_string_literal: true

module API
  module Entities
    class ProjectIntegrationBasic < Grape::Entity
      expose :id, documentation: { type: 'integer', example: 75 }
      expose :title, documentation: { type: 'string', example: 'Jenkins CI' }
      expose :slug, documentation: { type: 'integer', example: 'jenkins' } do |integration|
        integration.to_param.dasherize
      end
      expose :created_at, documentation: { type: 'dateTime', example: '2019-11-20T11:20:25.297Z' }
      expose :updated_at, documentation: { type: 'dateTime', example: '2019-11-20T12:24:37.498Z' }
      expose :active, documentation: { type: 'boolean' }
      expose :commit_events, documentation: { type: 'boolean' }
      expose :push_events, documentation: { type: 'boolean' }
      expose :issues_events, documentation: { type: 'boolean' }
      expose :confidential_issues_events, documentation: { type: 'boolean' }
      expose :merge_requests_events, documentation: { type: 'boolean' }
      expose :tag_push_events, documentation: { type: 'boolean' }
      expose :note_events, documentation: { type: 'boolean' }
      expose :confidential_note_events, documentation: { type: 'boolean' }
      expose :pipeline_events, documentation: { type: 'boolean' }
      expose :wiki_page_events, documentation: { type: 'boolean' }
      expose :job_events, documentation: { type: 'boolean' }
      expose :comment_on_event_enabled, documentation: { type: 'boolean' }
    end
  end
end