index
int64 0
0
| repo_id
stringclasses 829
values | file_path
stringlengths 34
254
| content
stringlengths 6
5.38M
|
|---|---|---|---|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/schemas/contacts.rb
|
# frozen_string_literal: true
require 'va_profile/models/associated_person'
module Swagger::Schemas
class Contacts
include Swagger::Blocks
swagger_schema :Contacts do
key :required, [:data]
property :data, type: :array do
items do
property :id, type: :string
property :type, type: :string
property :attributes do
key :$ref, :Contact
end
end
end
property :meta, type: :object, description: 'Upstream response metadata'
end
swagger_schema :Contact do
key :required, %i[contact_type given_name family_name primary_phone]
property(
:contact_type,
type: :string,
enum: VAProfile::Models::AssociatedPerson::PERSONAL_HEALTH_CARE_CONTACT_TYPES
)
property :given_name, type: %i[string null]
property :family_name, type: %i[string null]
property :relationship, type: %i[string null]
property :address_line1, type: %i[string null]
property :address_line2, type: %i[string null]
property :address_line3, type: %i[string null]
property :city, type: %i[string null]
property :state, type: %i[string null]
property :zip_code, type: %i[string null]
property :primary_phone, type: %i[string null]
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/schemas/permission.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
class Permission
include Swagger::Blocks
swagger_schema :Permission do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
property :permission_type, type: :string, example: 'TextPermission'
property :permission_value, type: :boolean, example: true
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/schemas/address.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
class Address
include Swagger::Blocks
swagger_schema :Address do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
property :address do
property :type, type: :string, enum:
%w[
DOMESTIC
INTERNATIONAL
MILITARY
], example: 'DOMESTIC'
property :address_effective_date, type: :string, example: '1973-01-01T05:00:00.000+00:00'
property :address_one, type: :string, example: '140 Rock Creek Church Rd NW'
property :address_two, type: :string, example: ''
property :address_three, type: :string, example: ''
property :city, type: :string, example: 'Washington'
property :state_code, type: :string, example: 'DC'
property :zip_code, type: :string, example: '20011'
property :zip_suffix, type: :string, example: '1865'
end
property :control_information do
property :can_update, type: :boolean
property :corp_avail_indicator, type: :boolean
property :corp_rec_found_indicator, type: :boolean
property :has_no_bdn_payments_indicator, type: :boolean
property :is_competent_indicator, type: :boolean
property :indentity_indicator, type: :boolean
property :index_indicator, type: :boolean
property :no_fiduciary_assigned_indicator, type: :boolean
property :not_deceased_indicator, type: :boolean
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/schemas/intent_to_file.rb
|
# frozen_string_literal: true
require 'disability_compensation/responses/intent_to_files_response'
module Swagger
module Schemas
class IntentToFile
include Swagger::Blocks
swagger_schema :IntentToFileBase do
key :required, %i[
id
creation_date
expiration_date
participant_id
source
status
type
]
property :id, type: :string, example: '1'
property :creation_date, type: :string, example: '2018-01-21T19:53:45.810+00:00'
property :expiration_date, type: :string, example: '2018-02-21T19:53:45.810+00:00'
property :participant_id, type: :integer, example: 1
property :source, type: :string, example: 'EBN'
property :status, type: :string, enum: DisabilityCompensation::ApiProvider::IntentToFile::STATUS_TYPES,
example: 'active'
property :type, type: :string, enum: %w[
compensation
pension
survivor
], example: 'compensation'
end
swagger_schema :IntentToFiles do
property :data, type: :object do
property :attributes, type: :object do
key :required, %i[intent_to_file]
property :intent_to_file do
key :type, :array
items do
key :$ref, :IntentToFileBase
end
end
end
property :id, type: :string, example: nil
property :type, type: :string, example: 'intent_to_file'
end
end
swagger_schema :IntentToFile do
property :data, type: :object do
property :attributes, type: :object do
key :required, %i[intent_to_file]
property :intent_to_file, type: :object do
key :$ref, :IntentToFileBase
end
end
property :id, type: :string, example: nil
property :type, type: :string, example: 'intent_to_file'
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/schemas/letters.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
class Letters
include Swagger::Blocks
swagger_schema :Letters do
key :required, [:data]
property :data, type: :object do
property :attributes, type: :object do
key :required, %i[letters full_name]
property :letters do
key :type, :array
items do
key :$ref, :Letter
end
end
property :full_name, type: :string, example: 'Mark Webb'
end
property :id, type: :string, example: nil
property :type, type: :string, example: 'evss_letters_letters_response'
end
end
swagger_schema :Letter do
key :required, %i[name letter_type]
property :name, type: :string, example: 'Proof of Service Letter'
property :letter_type, type: :string, enum: %w[
commissary
proof_of_service
medicare_partd
minimum_essential_coverage
service_verification
civil_service
benefit_summary
benefit_summary_dependent
benefit_verification
certificate_of_eligibility
], example: 'proof_of_service'
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/schemas/upload_supporting_evidence.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
class UploadSupportingEvidence
include Swagger::Blocks
swagger_schema :UploadSupportingEvidence do
property :data, type: :object do
property :attributes, type: :object do
key :required, %i[guid]
property :guid, type: :string, example: '3c05b2f0-0715-4298-965d-f733465ed80a'
end
property :id, type: :string, example: '11'
property :type, type: :string, example: 'supporting_evidence_attachments'
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/schemas/countries.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
class Countries
include Swagger::Blocks
swagger_schema :Countries do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
key :required, [:countries]
property :countries do
key :type, :array
items do
key :required, [:name]
property :name, type: :string, example: 'USA'
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/schemas/evss_auth_error.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
class EVSSAuthError
include Swagger::Blocks
swagger_schema :EVSSAuthError do
key :required, [:errors]
property :errors do
key :type, :array
items do
key :required, %i[title detail code status]
property :title, type: :string, example: 'Forbidden'
property :detail,
type: :string,
example: \
'User does not have access to the requested resource due to missing values: corp_id, edipi'
property :code, type: :string, example: '403'
property :status, type: :string, example: '403'
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/gibct/meta.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Gibct
class Meta
include Swagger::Blocks
STATES = %i[
AK AL AR AS AZ CA CO CT DC DE FL FM GA GU HI IA
ID IL IN KS KY LA MA MD ME MH MI MN MO MP MS MT
NC ND NE BH NJ NM NV NY OH OK OR PA PR PW RI SC
SD TN TX UT VA VI VT WA WI WV WY
].freeze
swagger_schema :GibctVersion do
key :type, :object
key :required, %i[number created_at preview]
property :number, type: :integer, example: 1
property :created_at, type: :string, example: '2019-10-23T14:4:34.582Z'
property :preview, type: :boolean, example: false
end
swagger_schema :GibctState do
key :type, :object
STATES.each { |state| property state, type: :integer }
end
swagger_schema :GibctCountry do
key :type, :array
items do
key :type, :object
key :required, %i[name count]
property :name, type: :string, example: 'USA'
property :count, type: :integer, example: 1
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/gibct/institutions.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Gibct
class Institutions
include Swagger::Blocks
swagger_schema :GibctInstitutionsAutocomplete do
key :required, %i[data meta links]
property :data, type: :array, minItems: 0, uniqueItems: true do
items do
property :id, type: :integer
property :value, type: :string
property :label, type: :string
end
end
property :meta, '$ref': :GibctInstitutionsAutocompleteMeta
property :links, '$ref': :GibctInstitutionsSelfLinks
end
swagger_schema :GibctInstitutionsSearch do
key :required, %i[data meta links]
property :data, type: :array, maxItems: 10, uniqueItems: true do
items do
key :type, :object
key :required, %i[id type attributes links]
property :id, type: :string
property :type, type: :string, enum: ['institutions']
property :links, '$ref': :GibctInstitutionsSelfLinks
property :attributes do
key :$ref, :GibctInstitutionBase
property :type, type: :string,
enum: ['OJT', 'PRIVATE', 'FOREIGN', 'CORRESPONDENCE', 'FLIGHT', 'FOR PROFIT', 'PUBLIC']
end
end
end
property :meta, '$ref': :GibctInstitutionsSearchMeta
property :links, '$ref': :GibctInstitutionsSearchLinks
end
swagger_schema :GibctInstitution do
key :type, :object
key :required, %i[data meta]
property :data, type: :object do
key :required, %i[id type attributes links]
property :id, type: :string
property :type, type: :string, enum: ['institutions']
property :links, '$ref': :GibctInstitutionsSelfLinks
property :attributes do
key :$ref, :GibctInstitutionBase
property :type, type: :string,
enum: ['OJT', 'PRIVATE', 'FOREIGN', 'CORRESPONDENCE', 'FLIGHT', 'FOR PROFIT', 'PUBLIC']
property :flight, type: :boolean
property :correspondence, type: :boolean
property :cross, type: %i[null string]
property :ope, type: %i[null string]
property :ope6, type: %i[null string]
property :undergrad_enrollment, type: %i[null integer]
property :student_veteran, type: :boolean
property :student_veteran_link, type: %i[null string]
property :dodmou, type: :boolean
property :sec_702, type: %i[null boolean]
property :vet_success_name, type: %i[null string]
property :vet_success_email, type: %i[null string]
property :credit_for_mil_training, type: %i[null boolean]
property :vet_poc, type: %i[null boolean]
property :student_vet_grp_ipeds, type: %i[null boolean]
property :soc_member, type: %i[null boolean]
property :retention_rate_veteran_ba, type: %i[null number]
property :retention_all_students_ba, type: %i[null number]
property :retention_rate_veteran_otb, type: %i[null number]
property :retention_all_students_otb, type: %i[null number]
property :persistance_rate_veteran_ba, type: %i[null number]
property :persistance_rate_veteran_otb, type: %i[null number]
property :graduation_rate_veteran, type: %i[null number]
property :graduation_rate_all_students, type: %i[null number]
property :transfer_out_rate_veteran, type: %i[null number]
property :transfer_out_rate_all_students, type: %i[null number]
property :salary_all_students, type: %i[null number]
property :repayment_rate_all_students, type: %i[null number]
property :avg_stu_loan_debt, type: %i[null number]
property :calendar, type: %i[null string]
property :online_all, type: %i[null boolean]
property :p911_tuition_fees, type: :number
property :p911_recipients, type: :integer
property :p911_yellow_ribbon, type: %i[null number]
property :p911_yr_recipients, type: %i[null integer]
property :accredited, type: :boolean
property :accreditation_type, type: %i[null string]
property :accreditation_status, type: %i[null string]
property :ownership_name, type: %i[null string]
property :complaints, type: :object do
property :facility_code, type: :integer
property :financial_by_fac_code, type: :integer
property :quality_by_fac_code, type: :integer
property :refund_by_fac_code, type: :integer
property :marketing_by_fac_code, type: :integer
property :accreditation_by_fac_code, type: :integer
property :degree_requirements_by_fac_code, type: :integer
property :student_loans_by_fac_code, type: :integer
property :grades_by_fac_code, type: :integer
property :credit_transfer_by_fac_code, type: :integer
property :credit_job_by_fac_code, type: %i[null integer]
property :job_by_fac_code, type: :integer
property :transcript_by_fac_code, type: :integer
property :other_by_fac_code, type: :integer
property :main_campus_roll_up, type: :integer
property :financial_by_ope_id_do_not_sum, type: :integer
property :quality_by_ope_id_do_not_sum, type: :integer
property :refund_by_ope_id_do_not_sum, type: :integer
property :marketing_by_ope_id_do_not_sum, type: :integer
property :accreditation_by_ope_id_do_not_sum, type: :integer
property :degree_requirements_by_ope_id_do_not_sum, type: :integer
property :student_loans_by_ope_id_do_not_sum, type: :integer
property :grades_by_ope_id_do_not_sum, type: :integer
property :credit_transfer_by_ope_id_do_not_sum, type: :integer
property :jobs_by_ope_id_do_not_sum, type: :integer
property :transcript_by_ope_id_do_not_sum, type: :integer
property :other_by_ope_id_do_not_sum, type: :integer
end
end
end
property :meta, '$ref': :GibctInstitutionsShowMeta
end
swagger_schema :GibctInstitutionsAutocompleteMeta do
key :type, :object
key :required, %i[version term]
property :version, '$ref': :GibctVersion
property :term, type: :string
end
swagger_schema :GibctInstitutionsSearchMeta do
key :type, :object
key :required, %i[version count facets]
property :version, '$ref': :GibctVersion
property :count, type: :integer
property :facets, type: :object do
key :required, %i[
category type state country student_vet_group
yellow_ribbon_scholarship principles_of_excellence
eight_keys_to_veteran_success stem_offered
independent_study online_only distance_learning
priority_enrollment
]
property :category, type: :object do
key :required, %i[school employer]
property :school, type: :integer
property :employer, type: :integer
end
property :type, type: :object do
property :correspondence, type: :integer
property :flight, type: :integer
property :foreign, type: :integer
property :'for profit', type: :integer
property :ojt, type: :integer
property :private, type: :integer
property :public, type: :integer
end
property :state, '$ref': :GibctState
property :country, '$ref': :GibctCountry
property :student_vet_group, '$ref': :null_boolean_counts
property :yellow_ribbon_scholarship, '$ref': :null_boolean_counts
property :principles_of_excellence, '$ref': :null_boolean_counts
property :eight_keys_to_veteran_success, '$ref': :null_boolean_counts
end
end
swagger_schema :GibctInstitutionsShowMeta do
key :type, :object
key :required, [:version]
property :version, '$ref': :GibctVersion
end
swagger_schema :GibctInstitutionsSearchLinks do
key :type, :object
key :required, %i[self first prev next last]
property :self, type: :string
property :first, type: :string
property :prev, type: %i[null string]
property :next, type: %i[null string]
property :last, type: :string
end
swagger_schema :GibctInstitutionBase do
key :required, %i[
name facility_code type city state zip country highest_degree locale_type
student_count caution_flag caution_flag_reason created_at updated_at bah
tuition_in_state tuition_out_of_state books student_veteran yr poe eight_keys
]
property :name, type: :string
property :facility_code, type: :string
property :city, type: %i[null string]
property :state, type: %i[null string]
property :zip, type: %i[null string]
property :country, type: %i[null string]
property :highest_degree, type: %i[null integer]
property :locale_type, type: %i[null string]
property :student_count, type: %i[null integer]
property :caution_flag, type: %i[null boolean]
property :caution_flag_reason, type: %i[null string]
property :created_at, type: :string
property :updated_at, type: :string
property :bah, type: %i[null number]
property :tuition_in_state, type: %i[null number]
property :tuition_out_of_state, type: %i[null number]
property :books, type: %i[null number]
property :student_veteran, type: %i[null boolean]
property :yr, type: %i[null boolean]
property :poe, type: %i[null boolean]
property :eight_keys, type: %i[null boolean]
property :ownership_name, type: %i[null string]
end
swagger_schema :GibctInstitutionsSelfLinks do
key :type, :object
key :required, [:self]
property :self, type: :string
end
swagger_schema :null_boolean_counts do
key :type, :object
key :required, %i[true false]
# rubocop:disable Lint/BooleanSymbol
property :true, type: %i[null integer]
property :false, type: %i[null integer]
# rubocop:enable Lint/BooleanSymbol
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/gibct/calculator_constants.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Gibct
class CalculatorConstants
include Swagger::Blocks
swagger_schema :GibctCalculatorConstants do
key :required, %i[data meta links]
property :data, type: :array, minItems: 0, uniqueItems: true do
items do
key :required, %i[id type attributes]
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
key :required, %i[name value]
property :name, type: :string
property :value, type: %i[null number string]
end
end
end
property :meta, '$ref': :GibctCalculatorConstantsMeta
property :links, '$ref': :GibctCalculatorConstantsSelfLinks
end
swagger_schema :GibctCalculatorConstantsSelfLinks do
key :type, :object
key :required, [:self]
property :self, type: :string
end
swagger_schema :GibctCalculatorConstantsMeta do
key :type, :object
key :required, [:version]
property :version, type: :null
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/gibct/institution_programs.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Gibct
class InstitutionPrograms
include Swagger::Blocks
swagger_schema :GibctInstitutionProgramsAutocomplete do
key :required, %i[data meta links]
property :data, type: :array, minItems: 0, uniqueItems: true do
items do
property :id, type: :integer, example: 1234, description: 'Unique program ID'
property :value, type: :string, example: '1X12345', description: 'Program institution facility code'
property :label, type: :string, example: 'COMPUTER SCIENCE', description: 'Program name'
end
end
property :meta, '$ref': :GibctInstitutionProgramsAutocompleteMeta
property :links, type: :object do
property :self, type: :string, example: 'http://localhost:3000/v0/institution_programs/autocomplete?name=code'
end
end
swagger_schema :GibctInstitutionProgramsSearch do
key :required, %i[data meta links]
property :data, type: :array, maxItems: 10, uniqueItems: true do
items do
key :type, :object
key :required, %i[id type attributes]
property :id, type: :string, example: '1973-01-01T05:00:00.000+00:00'
property :type, type: :string, enum: ['institution_programs']
property :attributes do
key :required, %i[facility_code description]
property :program_type, type: %i[null string],
enum: %w[IHL NCD OJT FLGT CORR],
description: 'The classification of the program, ex: IHL, NCD, OJT'
property :description, type: :string, example: 'COMPUTER SCIENCE',
description: 'Program name'
property :length_in_hours, type: %i[null string], example: '680',
description: 'Length of program (in hours)'
property :length_in_weeks, type: %i[null integer], example: 12,
description: 'Length of program (in weeks)'
property :facility_code, type: :string, example: '1X12345',
description: 'Program institution facility code'
property :institution_name, type: :string, example: 'CODE PLACE',
description: 'Program institution name'
property :city, type: %i[null string], example: 'ANYTOWN',
description: 'Program institution physical city location'
property :state, type: %i[null string], example: 'WA',
description: 'Program institution physical state location'
property :country, type: %i[null string], example: 'USA',
description: 'Program institution physical country location'
property :preferred_provider, type: %i[null boolean], example: false,
description: 'Program institution preferred provider indicator;
a provider that takes on the costs of the veterans education if
the requirements are not met'
property :tuition_amount, type: %i[null integer], example: 1000,
description: 'Program tuition amount'
property :va_bah, type: %i[null number], example: 220.0,
description: 'VA Basic Allowance for Housing'
property :dod_bah, type: %i[null integer], example: 200,
description: 'DOD Basic Allowance for Housing'
end
end
end
property :meta, '$ref': :GibctInstitutionProgramsSearchMeta
property :links, '$ref': :GibctInstitutionProgramsSearchLinks
end
swagger_schema :GibctInstitutionProgramsAutocompleteMeta do
key :type, :object
key :required, %i[version term]
property :version, '$ref': :GibctVersion
property :term, type: :string, example: 'code'
end
swagger_schema :GibctInstitutionProgramsSearchMeta do
key :type, :object
key :required, %i[version count facets]
property :version, '$ref': :GibctVersion
property :count, type: :integer, example: 1
property :facets, type: :object do
key :required, %i[type state country]
property :type, type: :object do
property :ihl, type: :integer, example: 0
property :ncd, type: :integer, example: 1
property :ojt, type: :integer, example: 0
property :flgt, type: :integer, example: 0
property :corr, type: :integer, example: 0
end
property :state, '$ref': :GibctState
property :country, '$ref': :GibctCountry
end
end
swagger_schema :GibctInstitutionProgramsSearchLinks do
key :type, :object
key :required, %i[self first prev next last]
property :self, type: :string, example: 'http://localhost:3000/v0/institution_programs/?name=code'
property :first, type: :string
property :prev, type: %i[null string]
property :next, type: %i[null string]
property :last, type: :string, example: 'http://localhost:3000/v0/institution_programs/?name=code&page=3&per_page=30'
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/gibct/yellow_ribbon_programs.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Gibct
class YellowRibbonPrograms
include Swagger::Blocks
swagger_schema :GibctYellowRibbonPrograms do
key :required, %i[data meta links]
property :data, type: :array, maxItems: 30, uniqueItems: true do
items do
key :type, :object
key :required, %i[id type attributes]
property :id, type: :string, example: '1226343'
property :type, type: :string, enum: ['yellow_ribbon_programs'], example: 'yellow_ribbon_programs'
property :attributes do
key :required, %i[city
contribution_amount
correspondence
country
degree_level
distance_learning
division_professional_school
facility_code
institution_id
insturl
latitude
longitude
name_of_institution
number_of_students
online_only
state
street_address
student_veteran
student_veteran_link
ungeocodable
year_of_yr_participation
zip]
property :city, type: %i[null string], example: 'Abilene',
description: 'The city name where the Yellow Ribbon Program is located.'
property :contribution_amount, type: %i[null string], example: '99999.0',
description: 'The contribution amount in dollars.'
property :correspondence, type: %i[null boolean], example: false,
description: 'Indicates that this is only a correspondence institution.'
property :country, type: %i[null string], example: 'USA',
description: 'The country where the Yellow Ribbon Program is located.'
property :distance_learning, type: %i[null boolean], example: false,
description: 'Indicates that this institution offers off-campus options'
property :degree_level, type: %i[null string], example: 'All',
description: 'The degree levels available to the Yellow Ribbon Program.'
property :division_professional_school, type: %i[null string], example: 'All',
description: 'The majors/minors of the Yellow Ribbon Program.'
property :facility_code, type: %i[null string], example: '31000143',
description: 'The faciliy code of the Yellow Ribbon Program.'
property :institution_id, type: %i[null integer], example: 20_405_111,
description: 'The institution ID the Yellow Ribbon Program belongs to.'
property :insturl, type: %i[null string], example: 'www.acu.edu',
description: 'The URL for the Yellow Ribbon Program\'s institution.'
property :latitude, type: %i[null number], format: :double, example: 32.0713829183673,
description: 'Geographic coordinate'
property :longitude, type: %i[null number], format: :double, example: -84.2393880204082,
description: 'Geographic coordinate'
property :name_of_institution, type: %i[null string], example: 'ABILENE CHRISTIAN UNIVERSITY',
description: 'The name of the school.'
property :number_of_students, type: %i[null integer], example: 99_999,
description: 'The number of students that can receive the benefit.'
property :online_only, type: %i[null boolean], example: false,
description: 'Indicates that this institution only offers online courses.'
property :state, type: %i[null string], example: 'TX',
description: 'The provincial state where the Yellow Ribbon Program is located.'
property :street_address, type: %i[null string], example: '1600 Campus Court',
description: 'The street address where the Yellow Ribbon Program is located.'
property :student_veteran, type: %i[null boolean], example: false,
description: 'Indicates that there is a student veterans group on campus.'
property :student_veteran_link, type: %i[null string], example: 'https://www.example.com',
description: 'Link to the student veterans group.'
property :ungeocodable, type: %i[null boolean], example: false,
description: 'Indicates a failure to resolve geographic coordinates.'
property :year_of_yr_participation, type: %i[null string], example: '"2018/2019"',
description: 'The school year that this Yellow Ribbon' \
'Program data is for.'
property :zip, type: %i[null string], example: '"31709"',
description: 'Postal code'
end
end
end
property :meta, '$ref': :GibctYellowRibbonProgramsMeta
property :links, '$ref': :GibctYellowRibbonProgramsLinks
end
swagger_schema :GibctYellowRibbonProgramsMeta do
key :type, :object
key :required, %i[version count]
property :version, '$ref': :GibctVersion
property :count, type: :integer, example: 790
end
swagger_schema :GibctYellowRibbonProgramsLinks do
key :type, :object
key :required, %i[self first prev next last]
property :self, type: :string
property :first, type: :string
property :prev, type: %i[null string]
property :next, type: %i[null string]
property :last, type: :string
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/contact_us/successful_inquiry_creation.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module ContactUs
class SuccessfulInquiryCreation
include Swagger::Blocks
swagger_schema :SuccessfulInquiryCreation do
key :required, %i[confirmationNumber dateSubmitted]
property :confirmationNumber,
type: :string,
example: '0000-0000-0000'
property :dateSubmitted,
type: :string,
example: '11-03-2020'
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/contact_us/inquiries_list.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module ContactUs
class InquiriesList
include Swagger::Blocks
swagger_schema :InquiriesList do
property :inquiries, type: :array do
items do
key :$ref, :InquirySummary
end
end
end
swagger_schema :InquirySummary do
property :subject, type: :string, example: 'Prosthetics'
property :confirmationNumber, type: :string, example: '000-010'
property :status, type: :string, example: 'OPEN'
property :creationTimestamp, type: :string, example: '2020-11-01T14:58:00+01:00'
property :lastActiveTimestamp, type: :string, example: '2020-11-04T13:00:00+01:00'
property :links, type: :object do
property :thread, type: :object do
property :href, type: :string
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/health/meta.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Health
class Meta
include Swagger::Blocks
swagger_schema :MetaPagination do
key :type, :object
key :required, [:pagination]
property :pagination, '$ref': :Pagination
end
swagger_schema :MetaFailedStationList do
key :type, :object
key :required, %i[updated_at failed_station_list]
property :updated_at, type: :string
property :failed_station_list, type: :string
end
swagger_schema :MetaFailedStationListSortPagination do
key :type, :object
key :required, %i[updated_at failed_station_list sort pagination]
property :updated_at, type: :string
property :failed_station_list, type: %i[null string]
property :pagination, '$ref': :Filter
property :pagination, '$ref': :Sort
property :pagination, '$ref': :Pagination
end
swagger_schema :MetaFilterSortPagination do
key :type, :object
key :required, %i[filter sort pagination]
property :pagination, '$ref': :Filter
property :pagination, '$ref': :Sort
property :pagination, '$ref': :Pagination
end
swagger_schema :MetaSortPagination do
key :type, :object
key :required, %i[sort pagination]
property :pagination, '$ref': :Sort
property :pagination, '$ref': :Pagination
end
swagger_schema :MetaSort do
key :type, :object
key :required, %i[sort]
property :pagination, '$ref': :Sort
end
swagger_schema :Filter do
key :type, :object
end
swagger_schema :Sort do
key :type, :object
end
swagger_schema :Pagination do
key :type, :object
key :required, %i[current_page per_page total_pages total_entries]
property :current_page, type: :integer
property :per_page, type: :integer
property :total_pages, type: :integer
property :total_entries, type: :integer
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/health/triage_teams.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Health
class TriageTeams
include Swagger::Blocks
swagger_schema :TriageTeams do
key :required, %i[data meta]
property :data, type: :array, minItems: 1, uniqueItems: true do
items do
key :$ref, :TriageTeamsBase
end
end
property :meta, '$ref': :MetaSort
end
swagger_schema :TriageTeamsBase do
key :required, %i[id type attributes]
property :id, type: :string
property :type, type: :string, enum: [:triage_teams]
property :attributes, type: :object do
key :required, %i[triage_team_id name relation_type]
property :triage_team_id, type: :integer
property :name, type: :string
property :relation_type, type: :string
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/health/folders.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Health
class Folders
include Swagger::Blocks
swagger_schema :Folders do
key :required, %i[data meta]
property :data, type: :array, minItems: 1, uniqueItems: true do
items do
key :$ref, :FolderBase
end
end
property :meta, '$ref': :MetaPagination
property :links, '$ref': :LinksAll
end
swagger_schema :Folder do
key :required, [:data]
property :data, type: :object, '$ref': :FolderBase
end
swagger_schema :FolderBase do
key :required, %i[id type attributes links]
property :id, type: :string
property :type, type: :string, enum: [:folders]
property :attributes, type: :object do
key :$ref, :FolderAttributes
end
property :links, '$ref': :LinksSelf
end
swagger_schema :FolderAttributes do
key :required, %i[folder_id name count unread_count system_folder]
property :folder_id, type: :integer
property :name, type: :string
property :count, type: :integer
property :unread_count, type: :integer
property :system_folder, type: :boolean
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/health/messages.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Health
class Messages
include Swagger::Blocks
swagger_schema :Messages do
key :required, %i[data meta]
property :data, type: :array, minItems: 1, uniqueItems: true do
items do
key :$ref, :DataAttributes
end
end
property :meta, '$ref': :MetaSortPagination
property :links, '$ref': :LinksAll
end
swagger_schema :MessagesThread do
key :required, [:data]
property :data, type: :array, minItems: 1, uniqueItems: true do
items do
key :$ref, :DataAttributes
end
end
property :meta, '$ref': :MetaSortPagination
property :links, '$ref': :LinksAll
end
swagger_schema :Message do
key :required, [:data]
property :data, type: :object, '$ref': :DataAttributesWithRelationships
property :included, '$ref': :Included
end
swagger_schema :Included do
key :required, [:included]
property :included, type: :array, minItems: 0, uniqueItems: true do
items do
key :required, %i[id type attributes links]
property :id, type: :string
property :type, type: :string, enum: [:attachments]
property :attributes, type: :object do
key :required, %i[message_id name]
property :message_id, type: :integer
property :name, type: :string
end
property :links, '$ref': :LinksDownload
end
end
end
swagger_schema :DataAttributes do
key :type, :object
key :required, %i[id type attributes links]
property :id, type: :string
property :type, type: :string, enum: %i[messages message_drafts]
property :attributes, '$ref': :MessageAttributes
property :links, '$ref': :LinksSelf
end
swagger_schema :DataAttributesWithRelationships do
key :type, :object
key :required, %i[id type attributes relationships links]
property :id, type: :string
property :type, type: :string, enum: %i[messages message_drafts]
property :attributes, '$ref': :MessageAttributes
property :relationships, '$ref': :Relationships
property :links, '$ref': :LinksSelf
end
swagger_schema :MessageAttributes do
key :type, :object
key :required, %i[message_id category subject body attachment sent_date sender_id
sender_name recipient_id recipient_name read_receipt]
property :message_id, type: :integer
property :category, type: :string
property :subject, type: :string
property :body, type: %i[null string]
property :attachment, type: :boolean
property :sent_date, type: %i[null string]
property :sender_id, type: :integer
property :sender_name, type: :string
property :recipient_id, type: :integer
property :recipient_name, type: :string
property :read_receipt, type: %i[null string]
property :triage_group_name, type: %i[null string]
property :proxy_sender_name, type: %i[null string]
end
swagger_schema :Relationships do
key :type, :object
key :required, [:attachments]
property :attachments, type: :object do
key :required, [:data]
property :data, type: :array, minItems: 0, uniqueItems: true do
items do
key :required, %i[id type]
property :id, type: :string
property :type, type: :string, enum: [:attachments]
end
end
end
end
swagger_schema :Categories do
key :required, [:data]
property :data, type: :object do
key :required, %i[id type attributes]
property :id, type: :string
property :type, type: :string, enum: [:categories]
property :attributes, type: :object do
key :required, [:message_category_type]
property :message_category_type, type: :array, minItems: 1, uniqueItems: true do
items do
key :type, :string
end
end
end
end
end
swagger_schema :MessageInput do
key :type, :object
key :required, %i[subject category recipient_id body]
property :draft_id, type: :integer
property :subject, type: :string
property :category, type: :string
property :recipient_id, type: :integer
property :body, type: :string
end
swagger_schema :AttachmentsInput do
key :type, :array
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/health/links.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Health
class Links
include Swagger::Blocks
swagger_schema :LinksAll do
key :type, :object
key :required, %i[self first prev next last]
property :self, type: :string
property :first, type: :string
property :prev, type: %i[string null]
property :next, type: %i[string null]
property :last, type: :string
end
swagger_schema :LinksSelf do
key :type, :object
key :required, [:self]
property :self, type: :string
end
swagger_schema :LinksDownload do
key :type, :object
key :required, [:download]
property :download, type: :string
end
swagger_schema :LinksTracking do
key :type, :object
key :required, %i[self prescription tracking_url]
property :self, type: :string
property :prescription, type: :string
property :tracking_url, type: :string
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/health/prescriptions.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Health
class Prescriptions
include Swagger::Blocks
swagger_schema :Prescriptions do
key :required, %i[data meta]
property :data, type: :array, minItems: 1, uniqueItems: true do
items do
key :$ref, :PrescriptionBase
end
end
property :meta do
key :$ref, :MetaFailedStationListSortPagination
end
property :links do
key :$ref, :LinksAll
end
end
swagger_schema :Prescription do
key :required, %i[data meta]
property :data, type: :object do
key :$ref, :PrescriptionBase
end
property :meta do
key :$ref, :MetaFailedStationList
end
end
swagger_schema :PrescriptionBase do
key :required, %i[id type attributes links]
property :id, type: :string
property :type, type: :string, enum: [:prescriptions]
property :attributes, type: :object do
key :required, %i[
prescription_id prescription_number prescription_name refill_status refill_submit_date
refill_date refill_remaining facility_name ordered_date quantity expiration_date
dispensed_date station_number is_refillable is_trackable
]
property :prescription_id, type: :integer
property :prescription_number, type: :string
property :prescription_name, type: :string
property :prescription_image, type: :string
property :refill_status, type: :string
property :refill_submit_date, type: %i[string null], format: :date
property :refill_date, type: :string, format: :date
property :refill_remaining, type: :integer
property :facility_name, type: :string
property :ordered_date, type: :string, format: :date
property :quantity, type: :string
property :expiration_date, type: :string, format: :date
property :dispensed_date, type: %i[string null], format: :date
property :sorted_dispensed_date, type: %i[string null], format: :date
property :station_number, type: :string
property :is_refillable, type: :boolean
property :is_trackable, type: :boolean
end
property :links do
key :$ref, :LinksSelf
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/health/trackings.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Health
class Trackings
include Swagger::Blocks
swagger_schema :Trackings do
key :required, %i[data meta links]
property :data, type: :array, minItems: 1, uniqueItems: true do
items do
key :$ref, :Tracking
end
end
property :meta do
key :$ref, :MetaFailedStationListSortPagination
end
property :links do
key :$ref, :LinksAll
end
end
swagger_schema :Tracking do
key :required, %i[id type attributes links]
property :id, type: :string
property :type, type: :string, enum: [:trackings]
property :attributes, type: :object do
key :$ref, :TrackingBase
end
property :links, type: :object do
key :$ref, :LinksTracking
end
end
swagger_schema :TrackingBase do
key :required, %i[
tracking_number prescription_id prescription_number prescription_name
facility_name rx_info_phone_number ndc_number shipped_date delivery_service
]
property :tracking_number, type: :string
property :prescription_id, type: :integer
property :prescription_number, type: :string
property :prescription_name, type: :string
property :facility_name, type: :string
property :rx_info_phone_number, type: :string
property :ndc_number, type: :string
property :shipped_date, type: :string, format: :date
property :delivery_service, type: :string
property :other_prescriptions, type: :array do
items do
key :$ref, :OtherPrescription
end
end
end
swagger_schema :OtherPrescription do
key :required, %i[prescription_name prescription_number ndc_number station_number]
property :prescription_name, type: :string
property :prescription_number, type: :string
property :ndc_number, type: :string
property :station_number, type: :string
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/async_transaction/vet360.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module AsyncTransaction
class Vet360
include Swagger::Blocks
swagger_schema :AsyncTransactionVet360 do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
property :transaction_status, type: :string, enum:
%w[
REJECTED
RECEIVED
RECEIVED_ERROR_QUEUE
RECEIVED_DEAD_LETTER_QUEUE
COMPLETED_SUCCESS
COMPLETED_NO_CHANGES_DETECTED
COMPLETED_FAILURE
], example: 'RECEIVED'
property :transaction_id, type: :string, example: '786efe0e-fd20-4da2-9019-0c00540dba4d'
property :type, type: :string, enum:
%w[
AsyncTransaction::VAProfile::AddressTransaction
AsyncTransaction::VAProfile::EmailTransaction
AsyncTransaction::VAProfile::InitializePersonTransaction
AsyncTransaction::VAProfile::PermissionTransaction
AsyncTransaction::VAProfile::TelephoneTransaction
], example: 'AsyncTransaction::VAProfile::EmailTransaction'
property :metadata, type: :array do
items type: :object do
property :code, type: :string, example: 'CORE103'
property :key, type: :string, example: '_CUF_NOT_FOUND'
property :severity, type: :string, example: 'ERROR'
property :text, type: :string, example: 'The tx for id/criteria XZY could not be found.'
end
end
end
end
end
swagger_schema :AsyncTransactionsVet360 do
key :required, [:data]
property :data,
type: :array do
items type: :object do
key :required, [:attributes]
property :attributes, type: :object do
property :transaction_status, type: :string, enum:
%w[
REJECTED
RECEIVED
RECEIVED_ERROR_QUEUE
RECEIVED_DEAD_LETTER_QUEUE
COMPLETED_SUCCESS
COMPLETED_NO_CHANGES_DETECTED
COMPLETED_FAILURE
], example: 'RECEIVED'
property :transaction_id, type: :string, example: '786efe0e-fd20-4da2-9019-0c00540dba4d'
property :type, type: :string, enum:
%w[
AsyncTransaction::VAProfile::AddressTransaction
AsyncTransaction::VAProfile::EmailTransaction
AsyncTransaction::VAProfile::InitializePersonTransaction
AsyncTransaction::VAProfile::PermissionTransaction
AsyncTransaction::VAProfile::TelephoneTransaction
], example: 'AsyncTransaction::VAProfile::AddressTransaction'
property :metadata, type: :array do
items type: :object do
property :code, type: :string, example: 'CORE103'
property :key, type: :string, example: '_CUF_NOT_FOUND'
property :severity, type: :string, example: 'ERROR'
property :text, type: :string, example: 'The tx for id/criteria XZY could not be found.'
end
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/gender_identity.rb
|
# frozen_string_literal: true
require 'va_profile/models/gender_identity'
module Swagger
module Schemas
module Vet360
class GenderIdentity
include Swagger::Blocks
swagger_schema :PutGenderIdentity do
key :required, %i[code]
property :code,
type: :string,
enum: ::VAProfile::Models::GenderIdentity::CODES,
example: 'F',
description: 'Describes gender identity code.'
end
swagger_schema :GenderIdentity do
property :data, type: :object do
key :required, [:attributes]
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
property :code, type: :string, example: 'F'
property :name, type: :string, example: 'Female'
property :source_system_user, type: :string, example: '123498767V234859'
property :source_date, type: :string, format: 'date-time', example: '2022-04-08T15:09:23.000Z'
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/states.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Vet360
class States
include Swagger::Blocks
swagger_schema :Vet360States do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
key :required, [:states]
property :states do
key :type, :array
items do
property :state_name, type: :string, example: 'Oregon'
property :state_code, type: :string, example: 'OR'
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/email.rb
|
# frozen_string_literal: true
require 'va_profile/models/email'
module Swagger
module Schemas
module Vet360
class Email
include Swagger::Blocks
swagger_schema :PostVet360Email do
key :required, %i[email_address]
property :email_address,
type: :string,
example: 'john@example.com',
minLength: 6,
maxLength: 255,
pattern: VAProfile::Models::Email::VALID_EMAIL_REGEX.inspect
property :confirmation_date,
type: %i[string null],
format: 'date-time',
example: nil,
description: "Confirmation date should only be provided if the email is 'confirmed' by the user"
end
swagger_schema :PutVet360Email do
key :required, %i[email_address id]
property :id, type: :integer, example: 1
property :email_address,
type: :string,
example: 'john@example.com',
minLength: 6,
maxLength: 255,
pattern: VAProfile::Models::Email::VALID_EMAIL_REGEX.inspect
property :confirmation_date,
type: %i[string null],
format: 'date-time',
example: '2025-01-01T00:00:00Z',
description: "Confirmation date should only be provided if the email is 'confirmed' by the user"
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/preferred_name.rb
|
# frozen_string_literal: true
require 'va_profile/models/preferred_name'
module Swagger
module Schemas
module Vet360
class PreferredName
include Swagger::Blocks
swagger_schema :PutPreferredName do
key :required, %i[text]
property :text,
type: :string,
example: 'Pat',
minLength: 1,
maxLength: 25,
description: 'Describes preferred name text.'
end
swagger_schema :PreferredName do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
property :text, type: :string, example: 'Pat'
property :source_system_user, type: :string, example: '123498767V234859'
property :source_date, type: :string, format: 'date-time', example: '2022-04-08T15:09:23.000Z'
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/zipcodes.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Vet360
class Zipcodes
include Swagger::Blocks
swagger_schema :Vet360Zipcodes do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
key :required, [:zipcodes]
property :zipcodes do
key :type, :array
items do
property :zip_code, type: :string, example: '97062'
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/communication_permission.rb
|
# frozen_string_literal: true
# rubocop:disable Metrics/MethodLength
module Swagger
module Schemas
module Vet360
module CommunicationPermission
def self.extended(base)
base.parameter do
key :name, :permission_data
key :in, :body
key :description, 'Communication permission details'
key :required, true
schema do
key :type, :object
key :required, %i[communication_item]
property :communication_item do
key :type, :object
key :required, %i[id communication_channel]
property :id, type: :integer
property :communication_channel do
key :type, :object
key :required, %i[id communication_permission]
property :id, type: :integer
property :communication_permission do
key :type, :object
key :required, %i[allowed]
property :allowed, type: :boolean
end
end
end
end
end
base.response 200 do
key :description, 'Create or update communication permission response'
schema do
key :type, :object
property :tx_audit_id, type: :string
property :status, type: :string
property :bio do
key :type, :object
property :create_date, type: :string
property :update_date, type: :string
property :tx_audit_id, type: :string
property :source_system, type: :string
property :source_date, type: :string
property :communication_permission_id, type: :integer
property :va_profile_id, type: :integer
property :communication_channel_id, type: :integer
property :communication_item_id, type: :integer
property :communication_channel_name, type: :string
property :communication_item_common_name, type: :string
property :allowed, type: :boolean
end
end
end
end
end
end
end
end
# rubocop:enable Metrics/MethodLength
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/telephone.rb
|
# frozen_string_literal: true
require 'va_profile/models/telephone'
module Swagger
module Schemas
module Vet360
class Telephone
include Swagger::Blocks
swagger_schema :PostVet360Telephone do
key :required, %i[phone_number area_code phone_type is_international country_code]
property :area_code,
type: :string,
example: '303',
minLength: 3,
maxLength: 3,
pattern: ::VAProfile::Models::Telephone::VALID_AREA_CODE_REGEX.inspect,
description: 'The three-digit code that begins a North American Numbering Plan (NANP) phone number
(U.S., Canada, and some Caribbean countries). Required when is_international is false. Set to null
for non-NANP numbers.'
property :country_code,
type: :string,
minLength: 1,
maxLength: 3,
example: '1',
default: '1',
pattern: ::VAProfile::Models::Telephone::VALID_COUNTRY_CODE_REGEX.inspect,
description: 'One- to three-digit code that routes the call to the country of that phone number.
Defaults to the NANP country code.'
property :extension,
type: :string,
example: '101',
maxLength: 6,
description: 'One-or-more digit number that must be dialed after reaching a main number, typically at
an establishment, in order to reach a specific party.'
property :is_international,
type: :boolean,
example: false,
default: false,
description: 'Indicates phone number has a non-NANP country code.'
property :is_textable,
type: :boolean,
example: true,
description: 'Indicates phone number is capable of receiving text messages.'
property :is_text_permitted,
type: :boolean,
example: true,
description: 'Indicates person has granted permission to receive text messages to phone number.'
property :is_voicemailable,
type: :boolean,
example: true,
description: 'Indicates person has granted consent to record a voice mail message on a phone number.'
property :phone_number,
type: :string,
example: '5551212',
minLength: 1,
maxLength: 14,
pattern: ::VAProfile::Models::Telephone::VALID_PHONE_NUMBER_REGEX.inspect,
description: 'Number that follows an area code for a NANP phone number, or a country code
for a non-NANP phone number.'
property :phone_type,
type: :string,
enum: ::VAProfile::Models::Telephone::PHONE_TYPES,
example: ::VAProfile::Models::Telephone::MOBILE,
description: 'Describes specific type of phone number.'
property :source_date,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z',
description: 'The date the source system received the last update to this bio.'
property :vet360_id,
type: :integer,
example: 1,
description: 'Unique Identifier of individual within VET360. Created by VET360 after it is validated
and accepted. May be considered PII.'
end
swagger_schema :PutVet360Telephone do
key :required, %i[id phone_number area_code phone_type is_international country_code]
property :id,
type: :integer,
example: 1
property :area_code,
type: :string,
example: '303',
minLength: 3,
maxLength: 3,
pattern: ::VAProfile::Models::Telephone::VALID_AREA_CODE_REGEX.inspect,
description: 'The three-digit code that begins a North American Numbering Plan (NANP) phone number
(U.S., Canada, and some Caribbean countries). Required when is_international is false. Set to null
for non-NANP numbers.'
property :country_code,
type: :string,
minLength: 1,
maxLength: 3,
example: '1',
default: '1',
pattern: ::VAProfile::Models::Telephone::VALID_COUNTRY_CODE_REGEX.inspect,
description: 'One- to three-digit code that routes the call to the country of that phone number.
Defaults to the NANP country code.'
property :extension,
type: :string,
example: '101',
maxLength: 10,
description: 'One-or-more digit number that must be dialed after reaching a main number, typically at
an establishment, in order to reach a specific party.'
property :is_international,
type: :boolean,
example: false,
default: false,
description: 'Indicates phone number has a non-NANP country code.'
property :is_textable,
type: :boolean,
example: true,
description: 'Indicates phone number is capable of receiving text messages.'
property :is_text_permitted,
type: :boolean,
example: true,
description: 'Indicates person has granted permission to receive text messages to phone number.'
property :is_voicemailable,
type: :boolean,
example: true,
description: 'Indicates person has granted consent to record a voice mail message on a phone number.'
property :phone_number,
type: :string,
example: '5551212',
minLength: 1,
maxLength: 14,
pattern: ::VAProfile::Models::Telephone::VALID_PHONE_NUMBER_REGEX.inspect,
description: 'Number that follows an area code for a NANP phone number, or a country code
for a non-NANP phone number.'
property :phone_type,
type: :string,
enum: ::VAProfile::Models::Telephone::PHONE_TYPES,
example: ::VAProfile::Models::Telephone::MOBILE,
description: 'Describes specific type of phone number.'
property :source_date,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z',
description: 'The date the source system received the last update to this bio.'
property :vet360_id,
type: :integer,
example: 1,
description: 'Unique Identifier of individual within VET360. Created by VET360 after it is validated
and accepted. May be considered PII.'
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/permission.rb
|
# frozen_string_literal: true
require 'va_profile/models/permission'
module Swagger
module Schemas
module Vet360
class Permission
include Swagger::Blocks
swagger_schema :PostVet360Permission do
key :required, %i[permission_type permission_value]
property :permission_type,
type: :string,
enum: ::VAProfile::Models::Permission::PERMISSION_TYPES,
example: ::VAProfile::Models::Permission::TEXT,
description: 'Describes specific type of permission.'
property :permission_value,
type: :boolean,
example: true,
description: 'Designates if Permission is granted.'
property :source_date,
type: :string,
format: 'date-time',
example: '2019-00-23T20:09:50Z',
description: 'The date the source system received the last update to this bio.'
property :vet360_id,
type: :integer,
example: 1,
description: 'Unique Identifier of individual within VET360. Created by VET360 after it is validated
and accepted. May be considered PII.'
end
swagger_schema :PutVet360Permission do
key :required, %i[id permission_type permission_value]
property :id,
type: :integer,
example: 1
property :permission_type,
type: :string,
enum: ::VAProfile::Models::Permission::PERMISSION_TYPES,
example: ::VAProfile::Models::Permission::TEXT,
description: 'Describes specific type of permission.'
property :permission_value,
type: :boolean,
example: true,
description: 'Designates if Permission is granted.'
property :source_date,
type: :string,
format: 'date-time',
example: '2019-00-23T20:09:50Z',
description: 'The date the source system received the last update to this bio.'
property :vet360_id,
type: :integer,
example: 1,
description: 'Unique Identifier of individual within VET360. Created by VET360 after it is validated
and accepted. May be considered PII.'
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/address.rb
|
# frozen_string_literal: true
require 'va_profile/models/address'
require 'va_profile/models/base_address'
module Swagger
module Schemas
module Vet360
class Address
include Swagger::Blocks
ADDRESS_FIELD_LIMIT = ::VAProfile::Models::BaseAddress::ADDRESS_FIELD_LIMIT
swagger_schema :Vet360AddressSuggestion do
key :type, :object
key :required, %i[
address_line1
city
country_code_iso3
address_type
]
property :address_line1,
type: :string,
example: '1493 Martin Luther King Rd',
maxLength: ADDRESS_FIELD_LIMIT
property :address_line2, type: :string, maxLength: ADDRESS_FIELD_LIMIT
property :address_line3, type: :string, maxLength: ADDRESS_FIELD_LIMIT
property :address_pou,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_POUS,
example: ::VAProfile::Models::Address::RESIDENCE
property :address_type,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_TYPES,
example: ::VAProfile::Models::Address::DOMESTIC
property :city, type: :string, example: 'Fulton', maxLength: 100
property :country_code_iso3,
type: :string,
example: 'USA',
minLength: 3,
maxLength: 3
property :international_postal_code, type: :string, example: '12345'
property :province, type: :string
property :state_code,
type: :string,
example: 'MS',
minLength: 2,
maxLength: 2
property :zip_code,
type: :string,
example: '38843',
minLength: 5,
maxLength: 5
property :zip_code_suffix,
type: :string,
example: '1234',
minLength: 4,
maxLength: 4
end
%i[
PostVet360DomesticAddress
PutVet360DomesticAddress
PostVet360InternationalAddress
PutVet360InternationalAddress
PostVet360MilitaryOverseasAddress
PutVet360MilitaryOverseasAddress
].each do |schema|
swagger_schema schema do
property :override_validation_key, type: :integer
property :address_line1,
type: :string,
example: '1493 Martin Luther King Rd',
maxLength: ADDRESS_FIELD_LIMIT,
pattern: 'US-ASCII'
property :address_line2,
type: :string,
maxLength: ADDRESS_FIELD_LIMIT,
pattern: 'US-ASCII'
property :address_line3,
type: :string,
maxLength: ADDRESS_FIELD_LIMIT,
pattern: 'US-ASCII'
end
end
swagger_schema :PostVet360DomesticAddress do
key :required, %i[
address_line1
address_pou
address_type
city
country_name
state_code
zip_code
]
property :address_pou,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_POUS,
example: ::VAProfile::Models::Address::RESIDENCE
property :address_type,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_TYPES,
example: ::VAProfile::Models::Address::DOMESTIC
property :city, type: :string, example: 'Fulton', maxLength: 100
property :country_name,
type: :string,
example: 'United States',
pattern: ::VAProfile::Models::Address::VALID_ALPHA_REGEX.inspect
property :state_code,
type: :string,
example: 'MS',
minLength: 2,
maxLength: 2,
pattern: ::VAProfile::Models::Address::VALID_ALPHA_REGEX.inspect
property :zip_code,
type: :string,
example: '38843',
maxLength: 5,
pattern: ::VAProfile::Models::Address::VALID_NUMERIC_REGEX.inspect
end
swagger_schema :PutVet360DomesticAddress do
key :required, %i[
address_line1
address_pou
address_type
city
country_name
id
state_code
zip_code
]
property :id, type: :integer, example: 1
property :address_pou,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_POUS,
example: ::VAProfile::Models::Address::RESIDENCE
property :address_type,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_TYPES,
example: ::VAProfile::Models::Address::DOMESTIC
property :city, type: :string, example: 'Fulton', maxLength: 100
property :country_name,
type: :string,
example: 'United States',
pattern: ::VAProfile::Models::Address::VALID_ALPHA_REGEX.inspect
property :state_code,
type: :string,
example: 'MS',
minLength: 2,
maxLength: 2,
pattern: ::VAProfile::Models::Address::VALID_ALPHA_REGEX.inspect
property :zip_code,
type: :string,
example: '38843',
maxLength: 5,
pattern: ::VAProfile::Models::Address::VALID_NUMERIC_REGEX.inspect
end
swagger_schema :PostVet360InternationalAddress do
key :required, %i[
address_line1
address_pou
address_type
international_postal_code
city
country_name
]
property :address_pou,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_POUS,
example: ::VAProfile::Models::Address::RESIDENCE
property :address_type,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_TYPES,
example: ::VAProfile::Models::Address::INTERNATIONAL
property :city, type: :string, example: 'Florence', maxLength: 100
property :country_name,
type: :string,
example: 'Italy',
pattern: ::VAProfile::Models::Address::VALID_ALPHA_REGEX.inspect
property :international_postal_code, type: :string, example: '12345'
end
swagger_schema :PutVet360InternationalAddress do
key :required, %i[
address_line1
address_pou
address_type
id
international_postal_code
city
country_name
]
property :id, type: :integer, example: 1
property :address_pou,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_POUS,
example: ::VAProfile::Models::Address::RESIDENCE
property :address_type,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_TYPES,
example: ::VAProfile::Models::Address::INTERNATIONAL
property :city, type: :string, example: 'Florence', maxLength: 100
property :country_name,
type: :string,
example: 'Italy',
pattern: ::VAProfile::Models::Address::VALID_ALPHA_REGEX.inspect
property :international_postal_code, type: :string, example: '12345'
end
swagger_schema :PostVet360MilitaryOverseasAddress do
key :required, %i[
address_line1
address_pou
address_type
city
country_name
state_code
zip_code
]
property :address_pou,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_POUS,
example: ::VAProfile::Models::Address::RESIDENCE
property :address_type,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_TYPES,
example: ::VAProfile::Models::Address::MILITARY
property :city, type: :string, example: 'Fulton', maxLength: 100
property :country_name,
type: :string,
example: 'United States',
pattern: ::VAProfile::Models::Address::VALID_ALPHA_REGEX.inspect
property :state_code,
type: :string,
example: 'MS',
minLength: 2,
maxLength: 2,
pattern: ::VAProfile::Models::Address::VALID_ALPHA_REGEX.inspect
property :zip_code,
type: :string,
example: '38843',
maxLength: 5,
pattern: ::VAProfile::Models::Address::VALID_NUMERIC_REGEX.inspect
end
swagger_schema :PutVet360MilitaryOverseasAddress do
key :required, %i[
address_line1
address_pou
address_type
city
country_name
id
state_code
zip_code
]
property :id, type: :integer, example: 1
property :address_pou,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_POUS,
example: ::VAProfile::Models::Address::RESIDENCE
property :address_type,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_TYPES,
example: ::VAProfile::Models::Address::MILITARY
property :city, type: :string, example: 'Fulton', maxLength: 100
property :country_name,
type: :string,
example: 'United States',
pattern: ::VAProfile::Models::Address::VALID_ALPHA_REGEX.inspect
property :state_code,
type: :string,
example: 'MS',
minLength: 2,
maxLength: 2,
pattern: ::VAProfile::Models::Address::VALID_ALPHA_REGEX.inspect
property :zip_code,
type: :string,
example: '38843',
maxLength: 5,
pattern: ::VAProfile::Models::Address::VALID_NUMERIC_REGEX.inspect
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/contact_information.rb
|
# frozen_string_literal: true
require 'va_profile/contact_information/v2/person_response'
require 'va_profile/contact_information/v2/service'
require 'va_profile/models/address'
require 'va_profile/models/telephone'
require 'common/models/redis_store'
require 'common/models/concerns/cache_aside'
module Swagger
module Schemas
module Vet360
class ContactInformation
include Swagger::Blocks
swagger_schema :Vet360ContactInformation do
property :data, type: :object do
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
property :vet360_contact_information, type: :object do
property :email, type: :object do
property :id, type: :integer, example: 323
property :email_address, type: :string, example: 'john@example.com'
property :created_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :confirmation_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_end_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_start_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :source_date,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :updated_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :verification_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
end
property :residential_address, type: :object do
property :address_line1, type: :string, example: '1493 Martin Luther King Rd'
property :address_line2, type: %i[string null]
property :address_line3, type: %i[string null]
property :address_pou, type: :string, example: ::VAProfile::Models::Address::RESIDENCE
property :address_type,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_TYPES,
example: ::VAProfile::Models::Address::DOMESTIC
property :bad_address, type: :boolean
property :city, type: :string, example: 'Fulton'
property :country_code_iso3, type: %i[string], example: 'USA'
property :country_code_fips, type: %i[string null], example: 'US'
property :id, type: :integer, example: 123
property :international_postal_code, type: %i[string null], example: '54321'
property :latitude, type: %i[number null], example: 38.901
property :longitude, type: %i[number null], example: -77.0347
property :province, type: %i[string null]
property :state_code, type: :string, example: 'NY'
property :zip_code, type: :string, example: '97062'
property :zip_code_suffix, type: %i[string null], example: '1234'
property :geocode_precision, type: %i[number null], example: 100.0
property :geocode_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :created_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_end_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_start_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :source_date,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :updated_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
end
property :mailing_address, type: :object do
property :address_line1, type: :string, example: '1493 Martin Luther King Rd'
property :address_line2, type: %i[string null]
property :address_line3, type: %i[string null]
property :address_pou,
type: :string,
example: ::VAProfile::Models::Address::CORRESPONDENCE
property :address_type,
type: :string,
enum: ::VAProfile::Models::Address::ADDRESS_TYPES,
example: ::VAProfile::Models::Address::DOMESTIC
property :bad_address, type: :boolean
property :city, type: :string, example: 'Fulton'
property :country_code_iso3, type: %i[string], example: 'USA'
property :country_code_fips, type: %i[string null], example: 'US'
property :id, type: :integer, example: 123
property :international_postal_code, type: %i[string null], example: '54321'
property :latitude, type: %i[number null], example: 38.901
property :longitude, type: %i[number null], example: -77.0347
property :province, type: %i[string null]
property :state_code, type: :string, example: 'NY'
property :zip_code, type: :string, example: '97062'
property :zip_code_suffix, type: %i[string null], example: '1234'
property :geocode_precision, type: %i[number null], example: 100.0
property :geocode_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :created_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_end_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_start_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :source_date,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :updated_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
end
property :mobile_phone, type: :object do
property :area_code, type: :string, example: '503'
property :country_code, type: :string, example: '1'
property :extension, type: %i[string null]
property :id, type: :integer, example: 123
property :is_international, type: :boolean
property :is_textable, type: :boolean
property :is_tty, type: :boolean
property :is_voicemailable, type: :boolean
property :phone_number, type: :string, example: '5551234'
property :phone_type, type: :string, example: ::VAProfile::Models::Telephone::MOBILE
property :created_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_end_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_start_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :source_date,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :updated_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
end
property :home_phone, type: :object do
property :area_code, type: :string, example: '503'
property :country_code, type: :string, example: '1'
property :extension, type: %i[string null]
property :id, type: :integer, example: 123
property :is_international, type: :boolean
property :is_textable, type: :boolean
property :is_tty, type: :boolean
property :is_voicemailable, type: :boolean
property :phone_number, type: :string, example: '5551234'
property :phone_type, type: :string, example: ::VAProfile::Models::Telephone::HOME
property :created_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_end_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_start_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :source_date,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :updated_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
end
property :work_phone, type: :object do
property :area_code, type: :string, example: '503'
property :country_code, type: :string, example: '1'
property :extension, type: %i[string null]
property :id, type: :integer, example: 123
property :is_international, type: :boolean
property :is_textable, type: :boolean
property :is_tty, type: :boolean
property :is_voicemailable, type: :boolean
property :phone_number, type: :string, example: '5551234'
property :phone_type, type: :string, example: ::VAProfile::Models::Telephone::WORK
property :created_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_end_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_start_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :source_date,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :updated_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
end
property :temporary_phone, type: :object do
property :area_code, type: :string, example: '503'
property :country_code, type: :string, example: '1'
property :extension, type: %i[string null]
property :id, type: :integer, example: 123
property :is_international, type: :boolean
property :is_textable, type: :boolean
property :is_tty, type: :boolean
property :is_voicemailable, type: :boolean
property :phone_number, type: :string, example: '5551234'
property :phone_type, type: :string, example: ::VAProfile::Models::Telephone::TEMPORARY
property :created_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_end_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_start_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :source_date,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :updated_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
end
property :fax_number, type: :object do
property :area_code, type: :string, example: '503'
property :country_code, type: :string, example: '1'
property :extension, type: %i[string null]
property :id, type: :integer, example: 123
property :is_international, type: :boolean
property :is_textable, type: :boolean
property :is_tty, type: :boolean
property :is_voicemailable, type: :boolean
property :phone_number, type: :string, example: '5551234'
property :phone_type, type: :string, example: ::VAProfile::Models::Telephone::FAX
property :created_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_end_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :effective_start_date,
type: %i[string null],
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :source_date,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
property :updated_at,
type: :string,
format: 'date-time',
example: '2018-04-21T20:09:50Z'
end
property :text_permission, type: :object do
property :id, type: :integer, example: 123
property :permission_type, type: :string, example: ::VAProfile::Models::Permission::TEXT
property :permission_value, type: :boolean, example: true
property :created_at,
type: :string,
format: 'date-time',
example: '2019-00-23T20:09:50Z'
property :effective_end_date,
type: %i[string null],
format: 'date-time',
example: '2019-00-23T20:09:50Z'
property :effective_start_date,
type: %i[string null],
format: 'date-time',
example: '2019-00-23T20:09:50Z'
property :source_date,
type: :string,
format: 'date-time',
example: '2019-00-23T20:09:50Z'
property :updated_at,
type: :string,
format: 'date-time',
example: '2019-00-23T20:09:50Z'
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/vet360/countries.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Vet360
class Countries
include Swagger::Blocks
swagger_schema :Vet360Countries do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
key :required, [:countries]
property :countries do
key :type, :array
items do
property :country_name, type: :string, example: 'Italy'
property :country_code_iso3, type: :string, example: 'ITA'
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/form526_submit_v2.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class Form526SubmitV2
include Swagger::Blocks
DATE_PATTERN = /^(\\d{4}|XXXX)-(0[1-9]|1[0-2]|XX)-(0[1-9]|[1-2][0-9]|3[0-1]|XX)$/
ADDRESS_PATTERN = /^([-a-zA-Z0-9'.,&#]([-a-zA-Z0-9'.,&# ])?)+$/
swagger_schema :Form526SubmitV2 do
key :required, [:form526]
property :form526, type: :object do
property :alternateNames, type: :array do
items type: :object do
key :$ref, :AlternateName
end
end
property :atRiskHousingSituation, type: :string, enum:
%w[
losingHousing
leavingShelter
other
]
property :attachments, type: :array do
items type: :object do
key :$ref, :Attachment
end
end
property :bankAccountNumber, type: :string, minLength: 4, maxLength: 17
property :bankAccountType, type: :string, enum:
%w[
Checking
Saving
]
property :bankName, type: :string, maxLength: 35
property :bankRoutingNumber, type: :string, pattern: /^\d{9}$/
property :completedFormAttachments, type: :array do
items type: :object do
key :required, %i[name attachmentId]
property :name, type: :string, example: 'private_medical_record.pdf'
property :confirmationCode, type: :string, example: 'd44d6f52-2e85-43d4-a5a3-1d9cb4e482a1'
property :attachmentId, type: :string
end
end
property :confinements, type: :array do
items do
key :$ref, :DateRangeAllRequired
end
end
property :employmentRequestAttachments, type: :array do
items type: :object do
key :required, %i[name attachmentId]
property :name, type: :string, example: 'private_medical_record.pdf'
property :confirmationCode, type: :string, example: 'd44d6f52-2e85-43d4-a5a3-1d9cb4e482a1'
property :attachmentId, type: :string, enum: ['L115']
end
end
property :form0781, type: :object do
key :$ref, :Form0781
end
property :form4142, type: :object do
key :$ref, :Form4142
end
property :form8940, type: :object do
key :$ref, :Form8940
end
property :forwardingAddress, type: :object do
key :$ref, :ForwardingAddress
end
property :hasTrainingPay, type: :boolean
property :homelessHousingSituation, type: :string, enum:
%w[
shelter
notShelter
anotherPerson
other
]
property :homelessOrAtRisk, type: :string, enum:
%w[
no
homeless
atARisk
]
property :homelessnessContact, type: :object do
property :name,
type: :string,
minLength: 1,
maxLength: 100,
pattern: %r{^([a-zA-Z0-9\-/']+( ?))*$}
property :phoneNumber,
type: :string,
pattern: /^\\d{10}$/
end
property :isVaEmployee, type: :boolean
property :mailingAddress, type: :object do
key :$ref, :AddressRequiredFields
end
property :mentalChanges, type: :object do
key :$ref, :MentalChanges
end
property :militaryRetiredPayBranch, type: :string, enum:
[
'Air Force',
'Army',
'Coast Guard',
'Marine Corps',
'National Oceanic and Atmospheric Administration',
'Navy',
'Public Health Service'
]
property :needToLeaveHousing, type: :boolean
property :newPrimaryDisabilities, type: :array do
items type: :object do
key :$ref, :NewDisability
end
end
property :newSecondaryDisabilities, type: :array do
items type: :object do
key :$ref, :NewDisability
end
end
property :otherAtRiskHousing, type: :string, minLength: 1, maxLength: 500
property :otherHomelessHousing, type: :string
property :phoneAndEmail, type: :object do
key :required, %i[primaryPhone emailAddress]
property :primaryPhone,
type: :string,
pattern: /^\\d{10}$/
property :emailAddress,
type: :string,
minLength: 6,
maxLength: 80,
pattern: /^[_A-Za-z0-9-]+(\\.[_A-Za-z0-9-]+)*@[A-Za-z0-9-]+(\\.[A-Za-z0-9]+)*(\\.[A-Za-z]{2,})$/
end
property :privateMedicalRecordAttachments, type: :array do
items type: :object do
key :$ref, :PrivateMedicalRecordAttachment
end
end
property :ratedDisabilities,
type: :array,
minItems: 1,
maxItems: 100 do
items type: :object do
key :$ref, :RatedDisability
end
end
property :secondaryAttachment, type: :array do
items type: :object do
key :$ref, :SecondaryAttachment
end
end
property :separationPayBranch, type: :string, enum:
[
'VA Form 21-0781a - Statement in Support of Claim for PTSD Secondary to Personal Assault',
'Civilian Police Reports',
'Military Personnel Record',
'Medical Treatment Record - Government Facility',
'Medical Treatment Record - Non-Government Facility',
'DD214',
'Other Correspondence',
'Buddy/Lay Statement'
]
property :separationPayDate, type: :string
property :serviceInformation, type: :object do
items do
key :$ref, :ServiceInformation
end
end
property :standardClaim, type: :boolean, default: false
property :unemployabilityAttachments, type: :array do
items type: :object do
key :$ref, :UnemployabilityAttachments
end
end
property :vaTreatmentFacilities, type: :array do
items type: :object do
key :$ref, :VATreatmentFacility
end
end
property :waiveRetirementPay, type: :boolean
property :waiveTrainingPay, type: :boolean
end
end
swagger_schema :Attachment do
key :required, %i[name attachmentId]
property :name, type: :string, example: 'private_medical_record.pdf'
property :confirmationCode, type: :string, example: 'd44d6f52-2e85-43d4-a5a3-1d9cb4e482a1'
property :attachmentId, type: :string, enum:
%w[
L015
L018
L029
L702
L703
L034
L478
L048
L049
L023
L070
L450
L451
L222
L228
L229
L102
L107
L827
L115
L117
L159
L133
L139
L149
]
end
swagger_schema :AlternateName do
property :first,
type: :string,
example: 'John',
minLength: 1,
maxLength: 14,
pattern: %r{^([a-zA-Z0-9\-/']+( ?))+$}
property :middle,
type: :string,
example: 'Jonny',
minLength: 1,
maxLength: 14,
pattern: %r{^([a-zA-Z0-9\-/']+( ?))+$}
property :last,
type: :string,
example: 'Johnson',
minLength: 1,
maxLength: 14,
pattern: %r{^([a-zA-Z0-9\-/']+( ?))+$}
end
swagger_schema :ForwardingAddress do
# See link for country enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L68-L285
property :country, type: :string, example: 'USA'
property :addressLine1,
type: :string,
maxLength: 35,
pattern: ADDRESS_PATTERN
property :addressLine2,
type: :string,
maxLength: 35,
pattern: ADDRESS_PATTERN
property :addressLine3,
type: :string,
maxLength: 35,
pattern: ADDRESS_PATTERN
property :city,
type: :string,
maxLength: 30,
pattern: /^([-a-zA-Z0-9'.#]([-a-zA-Z0-9'.# ])?)+$/
# See link for state enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L286-L353
property :state, type: :string, example: 'OR'
property :zipCode,
type: :string,
pattern: /^\\d{5}(?:([-\\s]?)\\d{4})?$/
property :effectiveDate, type: :object do
key :$ref, :DateRange
end
end
swagger_schema :MentalChanges do
property :depression, type: :boolean
property :obsessive, type: :boolean
property :prescription, type: :boolean
property :substance, type: :boolean
property :hypervigilance, type: :boolean
property :agoraphobia, type: :boolean
property :fear, type: :boolean
property :other, type: :boolean
property :otherExplanation, type: :string
property :noneApply, type: :boolean
end
swagger_schema :PrivateMedicalRecordAttachment do
key :required, %i[name attachmentId]
property :name, type: :string
property :confirmationCode, type: :string
property :attachmentId, type: :string, enum: %w[L107 L023]
end
swagger_schema :SecondaryAttachment do
key :required, %i[name attachmentId]
property :name, type: :string
property :confirmationCode, type: :string
property :attachmentId, type: :string, enum:
%w[
L229
L018
L034
L048
L049
L029
L023
L015
]
end
swagger_schema :ServiceInformation do
key :required, [:servicePeriods]
property :servicePeriods,
type: :array,
minItems: 1,
maxItems: 100 do
items type: :object do
key :required, %i[serviceBranch dateRange]
property :serviceBranch, type: :string, enum:
[
'Air Force',
'Air Force Reserve',
'Air National Guard',
'Army',
'Army National Guard',
'Army Reserve',
'Coast Guard',
'Coast Guard Reserve',
'Marine Corps',
'Marine Corps Reserve',
'NOAA',
'Navy',
'Navy Reserve',
'Public Health Service'
]
property :dateRange, type: :array do
items do
key :$ref, :DateRangeAllRequired
end
end
end
end
property :separationLocation, type: :object do
items do
property :separationLocationCode,
type: :string,
example: '98283'
property :separationLocationName,
type: :string,
maxLength: 256,
pattern: %r{^([a-zA-Z0-9/\-'.#,*()&][a-zA-Z0-9/\-'.#,*()& ]?)*$},
example: 'AF Academy'
end
end
property :reservesNationalGuardService, type: :object do
items do
key :required, %i[unitName obligationTermOfServiceDateRange]
property :unitName,
type: :string,
maxLength: 256,
pattern: /^([a-zA-Z0-9\-'.#][a-zA-Z0-9\-'.# ]?)*$/
property :obligationTermOfServiceDateRange, type: :array do
items do
key :$ref, :DateRangeAllRequired
end
end
property :receivingTrainingPay, type: :boolean
property :title10Activation, type: :object do
items do
property :title10ActivationDate, type: :array do
key :$ref, :DateRange
end
property :anticipatedSeparationDate, type: :array do
key :$ref, :DateRange
end
end
end
end
end
end
swagger_schema :UnemployabilityAttachments do
key :required, %i[name attachmentId]
property :name, type: :string
property :confirmationCode, type: :string
property :attachmentId, type: :string, enum:
%w[
L149
L023
]
end
swagger_schema :VATreatmentFacility do
key :required, %i[treatmentCenterName treatedDisabilityNames]
property :treatmentCenterName,
type: :string,
maxLength: 100,
pattern: /^([a-zA-Z0-9\-'.#]([a-zA-Z0-9\-'.# ])?)+$/
property :treatmentDateRange, type: :array do
key :$ref, :DateRange
end
property :treatmentCenterAddress, type: :object do
key :required, [:country]
# See link for country enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L68-L285
property :country, type: :string, example: 'USA'
property :city,
type: :string,
maxLength: 30,
pattern: /^([-a-zA-Z0-9'.#]([-a-zA-Z0-9'.# ])?)+$/
# See link for state enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L286-L353
property :state, type: :string, example: 'OR'
end
property :treatedDisabilityNames,
type: :array,
minItems: 1,
maxItems: 100 do
items type: :string
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/form8940.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class Form8940
include Swagger::Blocks
swagger_schema :Form8940 do
property :unemployability, type: :object do
property :mostIncome, type: :number
property :yearEarned, type: :string
property :job, type: :string
property :disabilityPreventingEmployment, type: :string
property :underDoctorHopitalCarePast12M, type: :boolean
property :doctorProvidedCare, type: :array do
items type: :object do
key :$ref, :ProvidedCare
end
end
property :hospitalProvidedCare, type: :array do
items type: :object do
key :$ref, :ProvidedCare
end
end
property :disabilityAffectedEmploymentFullTimeDate,
type: :string,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::DATE_PATTERN
property :lastWorkedFullTimeDate,
type: :string,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::DATE_PATTERN
property :becameTooDisabledToWorkDate,
type: :string,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::DATE_PATTERN
property :mostEarningsInAYear, type: :string
property :yearOfMostEarnings, type: :string
property :occupationDuringMostEarnings, type: :string
property :previousEmployers, type: :array do
items type: :object do
key :$ref, :PreviousEmployer
end
end
property :disabilityPreventMilitaryDuties, type: :boolean
property :past12MonthsEarnedIncome,
type: :number,
minimum: 0,
maximum: 9_999_999.99
property :currentMonthlyEarnedIncome,
type: :number,
minimum: 0,
maximum: 9_999_999.99
property :leftLastJobDueToDisability, type: :boolean
property :leftLastJobDueToDisabilityRemarks, type: :string
property :receiveExpectDisabilityRetirement, type: :boolean
property :receiveExpectWorkersCompensation, type: :boolean
property :attemptedToObtainEmploymentSinceUnemployability, type: :boolean
property :appliedEmployers, type: :array do
items type: :object do
key :$ref, :AppliedEmployer
end
end
property :education, type: :string, enum:
[
'Some elementary school',
'Some high school',
'High school diploma or GED',
'Some college',
'Associate\'s degree',
'Bachelor’s degree',
'Master’s degree',
'Doctoral degree',
'Other'
]
property :receivedOtherEducationTrainingPreUnemployability, type: :boolean
property :otherEducationTrainingPreUnemployability, type: :array do
items type: :object do
property :name, type: :string
property :dates, type: :object do
key :$ref, :DateRange
end
end
end
property :remarks, type: :string
end
end
swagger_schema :ProvidedCare do
property :name, type: :string
property :address, type: :object do
key :$ref, :AddressNoRequiredFields
end
property :dates, type: :string
end
swagger_schema :PreviousEmployer do
property :name, type: :string
property :employerAddress, type: :object do
key :$ref, :AddressNoRequiredFields
end
property :phone,
type: :string,
pattern: /^\\d{10}$/
property :typeOfWork, type: :string
property :hoursPerWeek, type: :number, minLength: 0, maxLength: 999
property :dates, type: :object do
key :$ref, :DateRange
end
property :timeLostFromIllness, type: :string
property :mostEarningsInAMonth, type: :number, minimum: 0
property :inBusiness, type: :boolean
end
swagger_schema :AppliedEmployer do
property :name, type: :string
property :address, type: :object do
key :$ref, :AddressNoRequiredFields
end
property :workType, type: :string
property :date,
type: :string,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::DATE_PATTERN
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/separation_locations.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class SeparationLocations
include Swagger::Blocks
swagger_schema :SeparationLocations do
key :required, [:separation_locations]
property :separation_locations, type: :array do
items do
key :required, %i[code description]
property :code, type: :string, example: '98283'
property :description, type: :string, example: 'AF Academy'
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/date_range.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class DateRange
include Swagger::Blocks
swagger_schema :DateRange do
property :from,
type: :string,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::DATE_PATTERN,
example: '2019-10-XX'
property :to,
type: :string,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::DATE_PATTERN,
example: 'XXXX-12-31'
end
swagger_schema :DateRangeAllRequired do
key :required, %i[to from]
property :from,
type: :string,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::DATE_PATTERN,
example: '2019-10-XX'
property :to,
type: :string,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::DATE_PATTERN,
example: 'XXXX-12-31'
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/disability.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class Disability
include Swagger::Blocks
swagger_schema :NewDisability do
key :required, %i[condition cause]
property :condition, type: :string
property :cause, type: :string, enum:
%w[
NEW
SECONDARY
WORSENED
VA
]
property :classificationCode, type: :string
property :primaryDescription, type: :string
property :causedByDisability, type: :string
property :causedByDisabilityDescription, type: :string
property :specialIssues, type: :array do
items do
key :$ref, :SpecialIssue
end
end
property :worsenedDescription, type: :string
property :worsenedEffects, type: :string
property :vaMistreatmentDescription, type: :string
property :vaMistreatmentLocation, type: :string
property :vaMistreatmentDate, type: :string
end
swagger_schema :RatedDisability do
key :required, %i[name disabilityActionType]
property :name, type: :string
property :disabilityActionType, type: :string, enum:
%w[
NONE
NEW
SECONDARY
WORSENED
VA
]
property :specialIssues, type: :array do
items do
key :$ref, :SpecialIssue
end
end
property :ratedDisabilityId, type: :string
property :ratingDecisionId, type: :string
property :diagnosticCode, type: :number
property :classificationCode, type: :string
property :secondaryDisabilities, type: :array, maxItems: 100 do
items type: :object do
key :required, %i[name disabilityActionType]
property :name, type: :string
property :disabilityActionType, type: :string, enum:
%w[
NONE
NEW
SECONDARY
WORSENED
VA
]
property :specialIssues, type: :array do
items do
key :$ref, :SpecialIssue
end
end
property :ratedDisabilityId, type: :string
property :ratingDecisionId, type: :string
property :diagnosticCode, type: :number
property :classificationCode, type: :string
end
end
end
swagger_schema :SpecialIssue do
property :items, type: :string, enum:
[
'ALS',
'HEPC',
'POW',
'PTSD/1',
'PTSD/2',
'PTSD/3',
'PTSD/4',
'MST',
'38 USC 1151',
'ABA Election',
'Abandoned VDC Claim',
'AMC NOD Brokering Project',
'Administrative Decision Review - Level 1',
'Administrative Decision Review - Level 2',
'Agent Orange - Vietnam',
'Agent Orange - outside Vietnam or unknown',
'AMA SOC/SSOC Opt-In',
'Amyotrophic Lateral Sclerosis (ALS)',
'Annual Eligibility Report',
'Asbestos',
'AutoEstablish',
'Automated Drill Pay Adjustment',
'Automated Return to Active Duty',
'BDD – Excluded',
'Brokered - D1BC',
'Brokered - Internal',
'Burn Pit Exposure',
'C-123',
'COWC',
'Character of Discharge',
'Challenge',
'ChemBio',
'Claimant Service Verification Accepted',
'Combat Related Death',
'Compensation Service Review – AO Outside RVN & Ship',
'Compensation Service Review - Equitable Relief',
'Compensation Service Review - Extraschedular',
'Compensation Service Review – MG/CBRNE/Shad',
'Compensation Service Review - Opinion',
'Compensation Service Review - Over $25K',
'Compensation Service Review - POW',
'Compensation Service Review - Radiation',
'Decision Ready Claim',
'Decision Ready Claim - Deferred',
'Decision Ready Claim - Partial Deferred',
'Disability Benefits Questionnaire - Private',
'Disability Benefits Questionnaire - VA',
'DRC – Exam Review Complete Approved',
'DRC – Exam Review Complete Disapproved',
'DRC – Pending File Scan',
'DRC – Vendor Exam Recommendation',
'DTA Error – Exam/MO',
'DTA Error – Fed Recs',
'DTA Error – Other Recs',
'DTA Error – PMRs',
'Emergency Care – CH17 Determination',
'Enhanced Disability Severance Pay',
'Environmental Hazard - Camp Lejeune',
'Environmental Hazard – Camp Lejeune – Louisville',
'Environmental Hazard in Gulf War',
'Extra-Schedular 3.321(b)(1)',
'Extra-Schedular IU 4.16(b)',
'FDC Excluded - Additional Claim Submitted',
'FDC Excluded - All Required Items Not Submitted',
'FDC Excluded - Appeal Pending',
'FDC Excluded - Appeal submitted',
'FDC Excluded - Claim Pending',
'FDC Excluded - Claimant Declined FDC Processing',
'FDC Excluded - Evidence Received After FDC CEST',
'FDC Excluded - FDC Certification Incomplete',
'FDC Excluded - FTR to Examination',
'FDC Excluded - Necessary Form(s) not Submitted',
'FDC Excluded - Needs Non-Fed Evidence Development',
'FDC Excluded - requires INDPT VRFCTN of FTI',
'Fed Record Delay - No Further Dev',
'Force Majeure',
'Fully Developed Claim',
'Gulf War Presumptive',
'HIV',
'Hepatitis C',
'Hospital Adjustment Action Plan FY 18/19',
'IDES Deferral',
'JSRRC Request',
'Local Hearing',
'Local Mentor Review',
'Local Quality Review',
'Local Quality Review IPR',
'Medical Foster Home',
'Military Sexual Trauma (MST)',
'MQAS Separation and Severance Pay Audit',
'Mustard Gas',
'National Quality Review',
'Nehmer AO Peripheral Neuropathy',
'Nehmer Phase II',
'Non-ADL Notification Letter',
'Non-Nehmer AO Peripheral Neuropathy',
'Non-PTSD Personal Trauma',
'Potential Under/Overpayment',
'POW',
'PTSD - Combat',
'PTSD - Non-Combat',
'PTSD - Personal Trauma',
'RO Special issue 1',
'RO Special issue 2',
'RO Special Issue 3',
'RO Special Issue 4',
'RO Special Issue 5',
'RO Special Issue 6',
'RO Special Issue 7',
'RO Special Issue 8',
'RO Special Issue 9',
'RVSR Examination',
'Radiation',
'Radiation Radiogenic Disability Confirmed',
'Rating Decision Review - Level 1',
'Rating Decision Review - Level 2',
'Ready for Exam',
'Same Station Review',
'SHAD',
'Sarcoidosis',
'Simultaneous Award Adjustment Not Permitted',
'Specialized Records Request',
'Stage 1 Development',
'Stage 2 Development',
'Stage 3 Development',
'TBI Exam Review',
'Temp 100 Convalescence',
'Temp 100 Hospitalization',
'Tobacco',
'Tort Claim',
'Traumatic Brain Injury',
'Upfront Verification',
'VACO Special issue 1',
'VACO Special issue 2',
'VACO Special Issue 3',
'VACO Special Issue 4',
'VACO Special Issue 5',
'VACO Special Issue 6',
'VACO Special Issue 7',
'VACO Special Issue 8',
'VACO Special Issue 9',
'VASRD-Cardiovascular',
'VASRD-Dental',
'VASRD-Digestive',
'VASRD-Endocrine',
'VASRD-Eye',
'VASRD-GU',
'VASRD-GYN',
'VASRD-Hemic',
'VASRD-Infectious',
'VASRD-Mental',
'VASRD-Musculoskeletal',
'VASRD-Neurological',
'VASRD-Respiratory/Auditory',
'VASRD-Skin',
'Vendor Exclusion - No Diagnosis',
'VONAPP Direct Connect',
'WARTAC',
'WARTAC Trainee'
]
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/submit_disability_form.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class SubmitDisabilityForm
include Swagger::Blocks
swagger_schema :SubmitDisabilityForm do
key :required, [:data]
property :data, type: :object do
property :attributes, type: :object do
key :required, [:job_id]
property :job_id, type: :string, example: 'b4a577edbccf1d805744efa9'
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/rating_info.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class RatingInfo
include Swagger::Blocks
swagger_schema :RatingInfo do
property :disability_decision_type_name, type: :string, example: 'Service Connected'
property :service_connected_combined_degree, type: :integer, example: 90
property :user_percent_of_disability, type: :integer, example: 90
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/form4142.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class Form4142
include Swagger::Blocks
swagger_schema :Form4142 do
property :limitedConsent, type: :string
property :providerFacility, type: :array, minItems: 1, maxItems: 100 do
items type: :object do
key :$ref, :ProviderFacility
end
end
end
swagger_schema :ProviderFacility do
key :required, %i[
providerFacilityName
treatmentDateRange
providerFacilityAddress
]
property :providerFacilityName, type: :string, minLength: 1, maxLength: 100
property :treatmentDateRange, type: :array do
items do
key :$ref, :DateRangeAllRequired
end
end
property :providerFaciltiyAddress, type: :object do
key :required, %i[
street
city
country
state
postalCode
]
property :street, type: :string, minLength: 1, maxLength: 20
property :street2, type: :string, minLength: 1, maxLength: 20
property :city, type: :string, minLength: 1, maxLength: 30
property :postalCode,
type: :string,
pattern: /^\\d{5}(?:([-\\s]?)\\d{4})?$/
# See link for country enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L68-L285
property :country,
type: :string,
example: 'USA'
# See link for state enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L286-L353
property :state,
type: :string,
example: 'OR'
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/rated_disabilities.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class RatedDisabilities
include Swagger::Blocks
swagger_schema :RatedDisabilities do
key :required, [:data]
property :data, type: :object do
property :attributes, type: :object do
key :required, [:rated_disabilities]
property :rated_disabilities do
items do
key :type, :object
key :$ref, :RatedDisability
end
end
end
property :id, type: :string, example: nil
property :type, type: :string, example: 'evss_disability_compensation_form_rated_disabilities_response'
end
end
swagger_schema :RatedDisability do
key :required,
%i[decision_code
decision_text
name
effective_date
rated_disability_id
rating_decision_id
rating_percentage
related_disability_date
special_issues]
property :decision_code, type: :string, example: 'SVCCONNCTED'
property :decision_text, type: :string, example: 'Service Connected'
property :name, type: :string, example: 'Diabetes mellitus0'
property :effective_date, type: :string, example: '2018-03-27T21:00:41.000+0000'
property :rated_disability_id, type: :string, example: '0'
property :rating_decision_id, type: :string, example: '63655'
property :rating_percentage, type: :integer, example: '100'
property :related_disability_date, type: :string, example: '2018-03-27T21:00:41.000+0000'
property :special_issues do
items do
key :type, :object
key :$ref, :SpecialIssue
end
end
end
swagger_schema :SpecialIssue do
key :required, %i[code name]
property :code, type: :string, example: 'TRM'
property :name, type: :string, example: 'Personal Trauma PTSD'
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/suggested_conditions.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class SuggestedConditions
include Swagger::Blocks
swagger_schema :SuggestedConditions do
key :required, [:data]
property :data do
key :type, :array
items do
key :$ref, :DisabilityContention
end
end
end
swagger_schema :DisabilityContention do
key :required, %i[id type attributes]
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
property :code, type: :integer, example: 460
property :medical_term, type: :string, example: 'arteriosclerosis'
property :lay_term, type: :string, example: 'hardened arteries'
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/job_status.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class JobStatus
include Swagger::Blocks
swagger_schema :JobStatus do
key :required, [:data]
property :data, type: :object do
property :attributes, type: :object do
property :claim_id, type: :integer
property :job_id, type: :string
property :submission_id, type: :integer
property :status, type: :string
property :ancillary_item_statuses, type: :array
end
property :id, type: :string
property :type, type: :string
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/address.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class Address
include Swagger::Blocks
swagger_schema :AddressRequiredFields do
key :required, %i[country city addressLine1]
# See link for country enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L68-L285
property :country, type: :string, example: 'USA'
property :addressLine1,
type: :string,
maxLength: 20,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::ADDRESS_PATTERN
property :addressLine2,
type: :string,
maxLength: 20,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::ADDRESS_PATTERN
property :addressLine3,
type: :string,
maxLength: 20,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::ADDRESS_PATTERN
property :city,
type: :string,
maxLength: 30,
pattern: /^([-a-zA-Z0-9'.#]([-a-zA-Z0-9'.# ])?)+$/
# See link for state enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L286-L353
property :state, type: :string, example: 'OR'
end
swagger_schema :AddressNoRequiredFields do
# See link for country enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L68-L285
property :country, type: :string, example: 'USA'
property :addressLine1,
type: :string,
maxLength: 20,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::ADDRESS_PATTERN
property :addressLine2,
type: :string,
maxLength: 20,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::ADDRESS_PATTERN
property :addressLine3,
type: :string,
maxLength: 20,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::ADDRESS_PATTERN
property :city,
type: :string,
maxLength: 30,
pattern: /^([-a-zA-Z0-9'.#]([-a-zA-Z0-9'.# ])?)+$/
# See link for state enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L286-L353
property :state, type: :string, example: 'OR'
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/form526/form0781.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Form526
class Form0781
include Swagger::Blocks
swagger_schema :Form0781 do
property :remarks, type: :string
property :additionalIncidentText, type: :string
property :additionalSecondaryIncidentText, type: :string
property :otherInformation, type: :array do
items type: :string
end
property :incidents, type: :array, minItems: 1 do
items type: :object do
key :$ref, :Incident
end
end
end
swagger_schema :Incident do
key :required, [:personalAssault]
property :personalAssault, type: :boolean
property :medalsCitations, type: :string
property :incidentDate,
type: :string,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::DATE_PATTERN,
example: '2019-10-XX'
property :incidentLocation, type: :object do
key :$ref, :IncidentLocation
end
property :incidentDescription, type: :string
property :unitAssigned, type: :string
property :unitAssignedDates, type: :object do
key :$ref, :DateRange
end
property :personsInvolved, type: :array do
items type: :object do
key :$ref, :PersonInvolved
end
end
property :sources, type: :array do
items type: :object do
key :$ref, :Source
end
end
end
swagger_schema :IncidentLocation do
# See link for country enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L68-L285
property :country, type: :string, example: 'USA'
property :city, type: :string, maxLength: 30, pattern: /^([-a-zA-Z0-9'.#]([-a-zA-Z0-9'.# ])?)+$/
# See link for state enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L286-L353
property :state, type: :string, example: 'OR'
property :additionalDetails, type: :string
end
swagger_schema :PersonInvolved do
property :name, type: :object do
property :first, type: :string
property :middle, type: :string
property :last, type: :string
end
property :rank, type: :string
property :injuryDeath, type: :string, enum:
%w[
killedInAction
killedNonBattle
woundedInAction
injuredNonBattle
other
]
property :injuryDeathOther, type: :string
property :injuryDeathDate,
type: :string,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::DATE_PATTERN,
example: '2019-10-XX'
property :unitAssigned, type: :string
property :description, type: :string
end
swagger_schema :Source do
property :name, type: :string
property :address, type: :object do
# See link for country enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L68-L285
property :country, type: :string
property :addressLine1,
type: :string,
maxLength: 20,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::ADDRESS_PATTERN
property :addressLine2,
type: :string,
maxLength: 20,
pattern: Swagger::Schemas::Form526::Form526SubmitV2::ADDRESS_PATTERN
property :city,
type: :string,
maxLength: 30,
pattern: /^([-a-zA-Z0-9'.#]([-a-zA-Z0-9'.# ])?)+$/
# See link for state enum
# https://github.com/department-of-veterans-affairs/vets-json-schema/blob/76083e33f175fb00392e31f1f5f90654d05f1fd2/dist/21-526EZ-ALLCLAIMS-schema.json#L286-L353
property :state, type: :string
property :zipCode,
type: :string,
pattern: /^\\d{5}(?:([-\\s]?)\\d{4})?$/
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/appeals/requests.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Appeals
class Requests
include Swagger::Blocks
swagger_schema :Appeals do
key :type, :object
key :required, %i[data]
property :data, type: :array do
items type: :object do
end
end
end
swagger_schema :AppealsErrors do
key :type, :object
items do
key :type, :object
property :title, type: :string
property :detail, type: :string
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/appeals/notice_of_disagreement.rb
|
# frozen_string_literal: true
require 'decision_review/schemas'
module Swagger
module Schemas
module Appeals
class NoticeOfDisagreement
include Swagger::Blocks
swagger_schema(
'nodContestableIssues',
DecisionReview::Schemas::NOD_CONTESTABLE_ISSUES_RESPONSE_200.merge(
example: JSON.parse(
File.read('spec/fixtures/notice_of_disagreements/NOD_contestable_issues_response_200.json')
)
).except('$schema')
)
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/schemas
|
code_files/vets-api-private/app/swagger/swagger/schemas/appeals/higher_level_review.rb
|
# frozen_string_literal: true
module Swagger
module Schemas
module Appeals
class HigherLevelReview
include Swagger::Blocks
VetsJsonSchema::SCHEMAS.fetch('HLR-CREATE-REQUEST-BODY')['definitions'].each do |k, v|
v.delete('$comment')
if k == 'hlrCreateDataAttributes'
v['oneOf'][1].delete('$comment')
schema = { description: v['description'] }.merge v['oneOf'][1]
swagger_schema 'hlrCreateDataAttributes', schema
next
end
if k == 'hlrCreateVeteran'
v['properties']['timezone'].delete('$comment')
swagger_schema 'hlrCreateVeteran', v
next
end
swagger_schema k, v
end
swagger_schema 'hlrCreate' do
example VetsJsonSchema::EXAMPLES.fetch 'HLR-CREATE-REQUEST-BODY'
end
VetsJsonSchema::SCHEMAS.fetch('HLR-SHOW-RESPONSE-200')['definitions'].each do |k, v|
v.delete('$comment')
swagger_schema(k == 'root' ? 'hlrShowRoot' : k, v) {}
end
swagger_schema 'hlrShowRoot' do
example VetsJsonSchema::EXAMPLES.fetch 'HLR-SHOW-RESPONSE-200'
end
# recursive
def self.remove_null_from_type_array(value)
case value
when Hash
value.reduce({}) do |new_hash, (k, v)|
next new_hash.merge(k => x_from_nullable_x_type(v)) if k == 'type' && type_is_nullable?(v)
new_hash.merge(k => remove_null_from_type_array(v))
end
when Array
value.map { |v| remove_null_from_type_array(v) }
else
value
end
end
def self.x_from_nullable_x_type(type_array)
nulls_index = type_array.index('null')
types_index = nulls_index.zero? ? 1 : 0
type_array[types_index]
end
def self.type_is_nullable?(type)
type.is_a?(Array) && type.length == 2 && type.include?('null')
end
swagger_schema(
'hlrContestableIssues',
remove_null_from_type_array(
VetsJsonSchema::SCHEMAS.fetch('HLR-GET-CONTESTABLE-ISSUES-RESPONSE-200')
).merge(
description: 'Fields may either be null or the type specified',
example: VetsJsonSchema::EXAMPLES.fetch('HLR-GET-CONTESTABLE-ISSUES-RESPONSE-200')
).except('$schema')
)
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/claim_letters.rb
|
# frozen_string_literal: true
# app/controllers/v0/claim_letters_controller.rb
module Swagger
module Requests
class ClaimLetters < ApplicationController
include Swagger::Blocks
swagger_path '/v0/claim_letters' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Get a list of claim letters\' metadata'
key :tags, %w[claim_letters]
key :operationId, 'getClaimLetters'
key :summary, 'Retrieve all claim letters\' metadata'
response 200 do
key :description, 'Claim Letters metadata list'
schema do
key :type, :array
items do
key :$ref, :ClaimLetter
end
end
end
end
end
swagger_path '/v0/claim_letters/{document_id}' do
operation :get do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::InternalServerError
key :tags, %w[claim_letters]
key :summary, 'Download a single PDF claim letter'
key :operationId, 'downloadPDFClaimLetter'
key :produces, ['application/pdf']
parameter do
key :in, :path
key :name, :document_id
key :pattern, '^{[0-9a-fA-F]{8}-([0-9a-fA-F]{4}-){3}[0-9a-fA-F]{12}}$'
key :description, 'Specifies the `document_id` (a UUID) of the claim letter to retrieve.\
Format: ***{AAAAAAAA-BBBB-CCCC-DDDD-EEEEEEEEEEEE}***. *Note the use of `{` and `}`. These are required.*'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Single Claim Letter PDF'
schema do
key :type, :file
end
end
end
end
swagger_schema :ClaimLetter do
property :document_id do
key :type, :string
key :pattern, '^{[0-9a-fA-F]{8}-([0-9a-fA-F]{4}-){3}[0-9a-fA-F]{12}}$'
end
property :series_id do
key :type, :string
key :pattern, '^{[0-9a-fA-F]{8}-([0-9a-fA-F]{4}-){3}[0-9a-fA-F]{12}}$'
end
property :version, type: :string
property :type_description, type: :string
property :type_id, type: :string
property :doc_type, type: :string
property :subject, type: %i[string null]
property :received_at, type: :string
property :source, type: :string
property :mime_type, type: :string
property :alt_doc_types, type: :string
property :restricted, type: :boolean
property :upload_date, type: :string
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/preneeds_claims.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class PreneedsClaims
include Swagger::Blocks
swagger_schema :PreneedAddress do
property :street, type: :string, example: '140 Rock Creek Church Rd NW'
property :street2, type: :string, example: ''
property :city, type: :string, example: 'Washington'
property :country, type: :string, example: 'USA'
property :state, type: :string, example: 'DC'
property :postalCode, type: :string, example: '20011'
end
swagger_schema :PreneedName do
property :first, type: :string, example: 'Jon'
property :middle, type: :string, example: 'Bob'
property :last, type: :string, example: 'Doe'
property :suffix, type: :string, example: 'Jr.'
property :maiden, type: :string, example: 'Smith'
end
swagger_schema :PreneedCemeteryAttributes do
property :cemetery_id, type: :string, example: '915', description: 'the same cemetary id again'
property :cemetery_type, type: :string, example: 'N', enum: %w[N S I A M]
property :name, type: :string, example: 'ABRAHAM LINCOLN NATIONAL CEMETERY'
property :num, type: :string, example: '915', description: 'the same cemetary id yet again, why not?'
end
swagger_schema :PreneedCemeteries do
key :required, [:data]
property :data, type: :array do
items do
property :id, type: :string, example: '915', description: 'the cemetary id'
property :type, type: :string, example: 'preneeds_cemeteries'
property :attributes, type: :object do
key :$ref, :PreneedCemeteryAttributes
end
end
end
end
swagger_path '/v0/preneeds/cemeteries' do
operation :get do
key :description, 'Get the cemeteries from EOAS (Eligibility Office Automation System)'
key :operationId, 'getCemetaries'
key :tags, %w[benefits_forms]
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :PreneedCemeteries
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/claim_documents.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class ClaimDocuments
include Swagger::Blocks
swagger_path '/v0/claim_attachments' do
operation :post do
extend Swagger::Responses::UnprocessableEntityError
extend Swagger::Responses::SavedForm
key :description, 'Submit a claim document'
key :operationId, 'addClaimDocument'
key :tags, %w[saved_claims claim_attachments]
parameter do
key :name, :form
key :in, :body
key :description, 'Claim Document Data'
key :required, true
schema do
key :required, %i[file form_id]
property :file, type: :object
property :form_id, type: :string, example: '21P-0000'
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/financial_status_reports.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class FinancialStatusReports
include Swagger::Blocks
swagger_path '/debts_api/v0/financial_status_reports' do
operation :post do
key :summary, 'Submits Form VA-5655 data to the Debt Management Center'
key :description, "Submits Form VA-5655 to the Debt Management Center.
The data is ingested by DMC's Financial Status Report API, where it is
then used to fill a PDF version of the VA-5655 form, which gets submitted
to filenet."
key :operationId, 'postFinancialStatusReport'
key :tags, %w[financial_status_reports]
parameter do
key :name, :request
key :in, :body
key :required, true
schema '$ref': :FinancialStatusReport
end
response 200 do
key :description, 'Form VA-5655 Financial Status Report successful submission'
schema do
property :content, type: :string
end
end
end
end
swagger_path '/debts_api/v0/financial_status_reports/download_pdf' do
operation :get do
key :summary, 'Downloads the filled copy of VA-5655 Financial Status Report'
key :operationId, 'getFinancialStatusReport'
key :tags, %w[financial_status_reports]
response 200 do
key :description, 'Financial Status Report download'
schema do
property :data, type: :string, format: 'binary'
end
end
end
end
swagger_path '/debts_api/v0/financial_status_reports/submissions' do
operation :get do
key :summary, 'Returns all Financial Status Report submissions for the current user'
key :description, 'Retrieves a list of all FSR (VA Form 5655) submissions for the authenticated user,
ordered by most recent first.'
key :operationId, 'getFinancialStatusReportSubmissions'
key :tags, %w[financial_status_reports]
response 200 do
key :description, 'Financial Status Report submissions list'
schema do
property :submissions, type: :array do
items do
property :id, type: :string, description: 'Submission UUID'
property :created_at, type: :string, format: 'date-time', description: 'Submission creation timestamp'
property :updated_at, type: :string, format: 'date-time', description: 'Last update timestamp'
property :state, type: :string, enum: %w[unassigned in_progress submitted failed],
description: 'Current state of the submission'
property :metadata, type: :object do
property :debt_type, type: :string, enum: %w[DEBT COPAY],
description: 'Type of debt included in the submission'
property :streamlined, type: :object, description: 'Streamlined waiver information' do
property :value, type: :boolean, description: 'Whether this is a streamlined submission'
property :type, type: :string, enum: %w[short long], description: 'Type of streamlined submission'
end
property :combined, type: :boolean,
description: 'Whether submission includes both VBA debts and VHA copays'
property :debt_identifiers, type: :array,
description: 'Array of unique identifiers for debts/copays ' \
'to help detect duplicate submissions' do
items do
key :type, :string
key :description,
'For VBA debts: composite ID (deductionCode + originalAR). For VHA copays: UUID'
end
end
end
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/onsite_notifications.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class OnsiteNotifications
include Swagger::Blocks
swagger_path '/v0/onsite_notifications/{id}' do
operation :patch do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::ValidationError
key :description, 'Update a onsite notification'
key :operationId, 'updateOnsiteNotification'
key :tags, %w[
my_va
]
parameter :authorization
key :produces, ['application/json']
key :consumes, ['application/json']
parameter do
key :name, :onsite_notification
key :in, :body
key :description, 'Onsite notification data'
key :required, true
schema do
key :type, :object
key :required, [:onsite_notification]
property(:onsite_notification) do
key :type, :object
key :required, [:dismissed]
property(:dismissed, type: :boolean)
end
end
end
response 404 do
key :description, 'Record not found'
schema do
key :$ref, :Errors
end
end
response 200 do
key :description, 'Onsite notification updated successfully'
schema do
key :type, :object
property(:data) do
key :$ref, :OnsiteNotification
end
end
end
end
end
swagger_path '/v0/onsite_notifications' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, "List a user's onsite notifications"
key :operationId, 'listOnsiteNotification'
key :tags, %w[my_va]
key :produces, ['application/json']
parameter :authorization
parameter :optional_page_number
parameter :optional_page_length
parameter do
key :name, :include_dismissed
key :in, :query
key :description, 'Whether to include dismissed notifications'
key :required, false
key :type, :boolean
end
response 200 do
key :description, 'Array of onsite notifications'
schema do
key :type, :object
property(:data) do
key :type, :array
items do
key :$ref, :OnsiteNotification
end
end
property :meta, '$ref': :MetaPagination
end
end
end
operation :post do
extend Swagger::Responses::ValidationError
key :description, 'Create an onsite notification'
key :operationId, 'addOnsiteNotification'
key :tags, %w[my_va]
key :produces, ['application/json']
key :consumes, ['application/json']
parameter do
key :name, :Authorization
key :in, :header
description = [
"Use JWT ES256 algorithm to encode payload {user: 'va_notify', iat: send_time, 'exp': send_time + X}",
"Put token in the header in the format 'Bearer ${token}'"
].join("\n")
key :description, description
key :required, true
key :type, :string
end
parameter do
key :name, :onsite_notification
key :in, :body
key :description, 'Onsite notification data'
key :required, true
schema do
key :type, :object
key :required, [:onsite_notification]
property(:onsite_notification) do
key :type, :object
key :required, %i[template_id va_profile_id]
property(:template_id, type: :string, example: 'f9947b27-df3b-4b09-875c-7f76594d766d')
property(:va_profile_id, type: :string, example: '505193')
end
end
end
response 403 do
key :description, 'Not authorized'
schema do
key :$ref, :Errors
end
end
response 200 do
key :description, 'Onsite notification created successfully'
schema do
key :type, :object
property(:data) do
key :$ref, :OnsiteNotification
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/digital_disputes.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class DigitalDisputes
include Swagger::Blocks
swagger_path '/debts_api/v0/digital_disputes' do
operation :post do
key :summary, 'Submits digital dispute documents to the Debt Management Center and VBS'
key :description, "Submits PDF documents for debt disputes to the Debt Management Center.
Veterans can upload one or more PDF files containing documentation supporting
their dispute of a debt."
key :operationId, 'postDigitalDispute'
key :tags, %w[digital_disputes]
key :consumes, ['multipart/form-data']
parameter do
key :name, 'files[]'
key :in, :formData
key :description, 'One or more PDF files (maximum 1MB each)'
key :required, true
key :type, :file
end
response 200 do
key :description, 'Digital dispute successful submission'
schema do
property :message, type: :string
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/form1010_ezr_attachments.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class Form1010EzrAttachments
include Swagger::Blocks
swagger_path '/v0/form1010_ezr_attachments' do
operation :post do
extend Swagger::Responses::BadRequestError
extend Swagger::Responses::UnprocessableEntityError
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::InternalServerError
key :description, 'Submit a 10-10EZR form attachment'
key :operationId, 'postForm1010EzrAttachment'
key :tags, %w[benefits_forms]
parameter :authorization
parameter do
key :name, :form1010_ezr_attachment
key :in, :body
key :description, '10-10EZR form attachment data'
key :required, true
schema do
key :required, %i[file_data]
property :file_data, type: :string, example: 'filename.pdf'
property :password, type: :string, example: 'My Password'
end
end
response 200 do
key :description, 'submit 10-10EZR attachment response'
schema do
property :data, type: :object do
key :required, %i[attributes]
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
key :required, %i[guid]
property :guid, type: :string
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/education_benefits_claims.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class EducationBenefitsClaims
include Swagger::Blocks
swagger_path '/v0/education_benefits_claims/{form_type}' do
operation :post do
extend Swagger::Responses::ValidationError
key :description, 'Submit an education benefits claim'
key :operationId, 'addEducationBenefitsClaim'
key :tags, %w[benefits_forms]
parameter do
key :name, :education_benefits_claim
key :in, :body
key :description, 'Education benefits form data'
key :required, true
schema do
key :$ref, :EducationBenefitsClaimInput
end
end
parameter do
key :name, :form_type
key :in, :path
key :description, 'Form code. Allowed values: 1990 1995 5490'
key :required, true
key :type, :string
end
response 200 do
key :description, 'create education benefits claim response'
schema do
key :$ref, :EducationBenefitsClaimData
end
end
end
end
swagger_schema :EducationBenefitsClaimInput do
key :required, [:form]
property :form do
key :type, :string
key :description, 'Should conform to vets-json-schema (https://github.com/department-of-veterans-affairs/vets-json-schema)'
end
end
swagger_schema :EducationBenefitsClaimData do
key :required, [:data]
property :data, type: :object do
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
property :form, type: :string
property :submitted_at, type: :string
property :regional_office, type: :string
property :confirmation_number, type: :string
end
end
end
swagger_path '/v0/education_benefits_claims/stem_claim_status' do
operation :get do
key :description, 'Get a list of user STEM benefit claims'
key :operationId, 'getStemClaimStatus'
key :tags, %w[
benefits_info
]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :EducationStemClaimStatusData
end
end
end
end
swagger_schema :EducationStemClaimStatusData do
key :required, [:data]
property :data, type: :array, minItems: 0, uniqueItems: true do
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
property :is_enrolled_stem,
type: :boolean,
example: true,
description: 'Submitted 10203 `is_enrolled_stem` form value'
property :is_pursuing_teaching_cert,
type: :boolean,
example: true,
description: 'Submitted 10203 `is_pursuing_teaching_cert` form value'
property :benefit_left,
type: :string,
example: 'none',
description: 'Submitted 10203 `benefit_left` form value'
property :remaining_entitlement,
type: :integer,
example: 127,
description: 'EVSS remaining entitlement in days'
property :automated_denial,
type: :boolean,
example: false,
description: 'Submitted 10203 `benefit_left` form value'
property :denied_at,
type: :string,
example: '2021-02-12T19:23:49.443Z',
description: 'STEM automated denial date time'
property :submitted_at,
type: :string,
example: '2021-02-12T19:15:22.178Z',
description: 'Form submission date time'
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/search_typeahead.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class SearchTypeahead
include Swagger::Blocks
swagger_path '/v0/search_typeahead' do
operation :get do
key :description, 'Returns a list of search query suggestions, from Search.gov, for the passed search query'
key :operationId, 'getSearchTypeaheadSuggestions'
key :tags, %w[
search_typeahead
]
parameter do
key :name, 'query'
key :in, :query
key :description, 'The search term being queried'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Debt letter download'
schema do
property :data, type: :string
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/health_care_applications.rb
|
# frozen_string_literal: true
require 'hca/enrollment_eligibility/status_matcher'
module Swagger
module Requests
class HealthCareApplications
include Swagger::Blocks
swagger_path '/v0/health_care_applications/rating_info' do
operation :get do
key :description, 'Get the user\'s service connected disability rating'
key :operationId, 'getDisabilityRating'
key :tags, %w[benefits_forms]
response 200 do
key :description, 'disability rating response'
schema do
property :data, type: :object do
key :required, %i[attributes]
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
key :required, %i[user_percent_of_disability]
property :user_percent_of_disability, type: :integer
end
end
end
end
end
end
swagger_path '/v0/health_care_applications/{id}' do
operation :get do
key :description, 'Show the status of a health care application'
key :operationId, 'getHealthCareApplication'
key :tags, %w[benefits_forms]
parameter do
key :name, :id
key :in, :path
key :description, 'ID of the application'
key :required, true
key :type, :string
end
response 200 do
key :description, 'get HCA response'
schema do
property :data, type: :object do
key :required, %i[attributes]
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
key :required, %i[state]
property :state, type: :string
property :form_submission_id, type: %i[string null]
property :timestamp, type: %i[string null]
end
end
end
end
end
end
swagger_path '/v0/health_care_applications' do
operation :post do
extend Swagger::Responses::ValidationError
extend Swagger::Responses::BackendServiceError
key :description, 'Submit a health care application'
key :operationId, 'addHealthCareApplication'
key :tags, %w[benefits_forms]
parameter :optional_authorization
parameter do
key :name, :form
key :in, :body
key :description, 'Health care application form data'
key :required, true
schema do
key :type, :string
end
end
response 200 do
key :description, 'submit health care application response'
schema do
key :$ref, :HealthCareApplicationSubmissionResponse
end
end
end
end
swagger_path '/v0/health_care_applications/enrollment_status' do
operation :get do
key :description, 'Check the status of a health care application.' \
' Non-logged in users must pass query parameters with user attributes.' \
' No parameters needed for logged in loa3 users.'
key :operationId, 'enrollmentStatusHealthCareApplication'
key :tags, %w[benefits_forms]
parameter :optional_authorization
response 200 do
key :description, 'enrollment_status response'
schema do
property :application_date, type: %i[string null], example: '2018-12-27T00:00:00.000-06:00'
property :enrollment_date, type: %i[string null], example: '2018-12-27T17:15:39.000-06:00'
property :preferred_facility, type: %i[string null], example: '988 - DAYT20'
property :parsed_status,
type: :string,
example: HCA::EnrollmentEligibility::Constants::ENROLLED,
enum: HCA::EnrollmentEligibility::StatusMatcher::ELIGIBLE_STATUS_CATEGORIES
property :effective_date, type: :string, example: '2019-01-02T21:58:55.000-06:00'
property :priority_group, type: %i[string null], example: 'Group 3'
property :can_submit_financial_info, type: %i[boolean null], example: true
end
end
end
operation :post do
key :description, 'Check the status of a health care application.' \
' Non-logged in users must pass request body parameters with user attributes.' \
' No parameters needed for logged in loa3 users.'
key :operationId, 'enrollmentStatusHealthCareApplication'
key :tags, %w[benefits_forms]
parameter :optional_authorization
parameter do
key :name, :userAttributes
key :in, :body
key :description, 'User attributes for enrollment status check'
key :required, false
schema do
property :userAttributes, type: :object do
property :veteranFullName, type: :object do
property :first, type: :string, description: 'user first name'
property :middle, type: :string, description: 'user middle name'
property :last, type: :string, description: 'user last name'
property :suffix, type: :string, description: 'user name suffix'
end
property :veteranDateOfBirth, type: :string, description: 'user date of birth'
property :veteranSocialSecurityNumber, type: :string, description: 'user ssn'
property :gender, type: :string, description: 'user gender'
end
end
end
response 200 do
key :description, 'enrollment_status response'
schema do
property :application_date, type: %i[string null], example: '2018-12-27T00:00:00.000-06:00'
property :enrollment_date, type: %i[string null], example: '2018-12-27T17:15:39.000-06:00'
property :preferred_facility, type: %i[string null], example: '988 - DAYT20'
property :parsed_status,
type: :string,
example: HCA::EnrollmentEligibility::Constants::ENROLLED,
enum: HCA::EnrollmentEligibility::StatusMatcher::ELIGIBLE_STATUS_CATEGORIES
property :effective_date, type: :string, example: '2019-01-02T21:58:55.000-06:00'
property :priority_group, type: %i[string null], example: 'Group 3'
property :can_submit_financial_info, type: %i[boolean null], example: true
end
end
end
end
# TODO: This is an interal monitoring endpoint, consider
# removing it from swagger documentation
swagger_path '/v0/health_care_applications/healthcheck' do
operation :get do
key :description, 'Check if the HCA submission service is up'
key :operationId, 'healthcheckHealthCareApplication'
key :tags, %w[benefits_forms]
response 200 do
key :description, 'health care application health check response'
schema do
key :$ref, :HealthCareApplicationHealthcheckResponse
end
end
end
end
swagger_path '/v0/health_care_applications/facilities' do
operation :get do
key :description, 'Retrieve a list of active healthcare facilities'
key :operationId, 'getFacilities'
key :tags, %w[benefits_forms]
parameter :optional_authorization
parameter do
key :name, :zip
key :in, :query
key :description, 'ZIP code for filtering facilities'
key :required, false
key :type, :string
end
parameter do
key :name, :state
key :in, :query
key :description, 'State for filtering facilities'
key :required, false
key :type, :string
end
parameter do
key :name, :lat
key :in, :query
key :description, 'Latitude for filtering facilities'
key :required, false
key :type, :string
end
parameter do
key :name, :long
key :in, :query
key :description, 'Longitude for filtering facilities'
key :required, false
key :type, :string
end
parameter do
key :name, :radius
key :in, :query
key :description, 'The radius around the location for facility search.'
key :required, false
key :type, :string
end
parameter do
key :name, :bbox
key :in, :query
key :description, 'Bounding box for facility search'
key :required, false
key :type, :string
end
parameter do
key :name, :visn
key :in, :query
key :description, 'VISN code for filtering facilities'
key :required, false
key :type, :string
end
parameter do
key :name, :type
key :in, :query
key :description, 'Type of facility'
key :required, false
key :type, :string
end
parameter do
key :name, :services
key :in, :query
key :description, 'Services offered at the facility'
key :required, false
key :type, :string
end
parameter do
key :name, :mobile
key :in, :query
key :description, 'Filter by mobile facilities'
key :required, false
key :type, :boolean
end
parameter do
key :name, :page
key :in, :query
key :description, 'Page number for pagination'
key :required, false
key :type, :integer
end
parameter do
key :name, :per_page
key :in, :query
key :description, 'Number of facilities per page'
key :required, false
key :type, :integer
end
parameter do
key :name, :facilityIds
key :in, :query
key :description, 'Array of facility IDs'
key :type, :array
items do
key :type, :string
end
key :collectionFormat, :multi
end
response 200 do
key :description, 'Successful response with a list of healthcare facilities'
schema do
key :$ref, :Facilities
end
end
end
end
swagger_path '/v0/health_care_applications/download_pdf' do
operation :post do
key :description, 'Download a pre-filled 10-10EZ PDF form.'
key :tags, %w[benefits_forms]
parameter do
key :name, :form
key :in, :body
key :description, 'The form data used to fill the PDF form.'
key :required, true
schema do
key :type, :string
end
end
response 200 do
key :description, 'PDF form download'
schema do
property :data, type: :string, format: 'binary'
end
end
end
end
swagger_schema :HealthCareApplicationSubmissionResponse do
key :required, %i[formSubmissionId timestamp success]
property :formSubmissionId, type: :integer
property :timestamp, type: :string
property :success, type: :boolean
end
swagger_schema :HealthCareApplicationHealthcheckResponse do
key :required, %i[formSubmissionId timestamp]
property :formSubmissionId, type: :integer
property :timestamp, type: :string
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/maintenance_windows.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class MaintenanceWindows
include Swagger::Blocks
swagger_path '/v0/maintenance_windows' do
operation :get do
key :description, 'Get a list of scheduled maintenance windows by service'
key :operationId, 'getMaintenanceWindows'
key :tags, ['site']
response 200 do
key :description, 'get list of scheduled maintenance windows'
schema do
key :$ref, :MaintenanceWindows
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/mvi_users.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class MviUsers
include Swagger::Blocks
swagger_path '/v0/mvi_users/{id}' do
operation :post do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::ForbiddenError
extend Swagger::Responses::UnprocessableEntityError
key :summary, 'Add user to MVI'
key :description, "Make Orchestrated Search call to the Master Veteran Index (MVI)
requesting that MVI make calls to upstream services to find or create the user's
CorpDB (Corp) ID, and possibly the user's Beneficiary Identification and Records
Locator Subsystem (BIRLS) ID. MVI will save the IDs it discovers to its own database.
The Corp and BIRLS IDs are required prerequisites for serving the 21-0966 Intent to File
form and 21-526EZ disability claim form to the client."
key :operationId, 'postMviUser'
key :tags, %w[form_526]
parameter :authorization
parameter do
key :name, :id
key :in, :path
key :description, "ID of the form. Allowed values: '21-0966' (Intent to File),
'21-526EZ' (Disability Compensation)"
key :required, true
key :type, :string
end
response 200 do
key :description, 'MVI Orchestrated Search returned a Success response'
schema do
property :message, type: :string, example: 'Success'
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/dependents_verifications.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class DependentsVerifications
include Swagger::Blocks
swagger_path '/v0/dependents_verifications' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, "Get the veteran's dependent status"
key :operationId, 'getDependentsVerifications'
key :tags, %w[dependents_verifications]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :DependentsVerifications
end
end
end
end
swagger_path '/v0/dependents_verifications' do
operation :post do
extend Swagger::Responses::SavedForm
key :description, 'Update diaries by sending true'
key :operationId, 'adDependentsVerifications'
key :tags, %w[dependents_verifications]
parameter :authorization
parameter do
key :name, :form
key :in, :body
key :description, 'Veteran Diary verification'
key :required, true
schema do
key :type, :string
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/travel_pay.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class TravelPay
include Swagger::Blocks
swagger_path '/travel_pay/v0/claims' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Get a list of travel reimbursment claim summaries'
key :operationId, 'getTravelPayClaims'
key :tags, %w[travel_pay]
parameter :authorization
parameter do
key :name, 'start_date'
key :in, :query
key :description, 'The start date of the date range. Defaults to 3 months ago.'
key :required, false
key :type, :string
end
parameter do
key :name, 'end_date'
key :in, :query
key :description, 'The end date of the date range. Defaults to today.'
key :required, false
key :type, :string
end
parameter do
key :name, 'page_number'
key :in, :query
key :description, 'Page number to start pagination on. Defaults to 1.'
key :required, false
key :type, :integer
end
response 200 do
key :description, 'Successfully retrieved claims for a user with pagination information'
schema do
property :data do
key :type, :array
items do
key :$ref, :TravelPayClaimSummary
end
end
property :metadata do
key :type, :object
property :status, type: :integer, example: 200
property :pageNumber, type: :integer, example: 1
property :totalRecordCount, type: :integer, example: 85
end
end
end
response 400 do
key :description, 'Bad request made'
schema do
property :error, type: :string, example: 'Bad Request: Invalid date format'
property :correlation_id, type: :string, example: '33333333-5555-4444-bbbb-222222444444'
end
end
end
end
swagger_path '/travel_pay/v0/claims/{id}' do
operation :get do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::BadRequestError
key :description, 'Get a single travel reimbursment claim details'
key :operationId, 'getTravelPayClaimById'
key :tags, %w[travel_pay]
parameter :authorization
parameter do
key :name, 'id'
key :in, :path
key :description, 'The non-PII/PHI id of a claim (UUID - any version)'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Successfully retrieved claim details for a user'
schema do
key :$ref, :TravelPayClaimDetails
end
end
response 400 do
key :description, 'Missing claim'
schema do
property :error, type: :string, example: 'Not Found: No claim with that id'
property :correlation_id, type: :string, example: '33333333-5555-4444-bbbb-222222444444'
end
end
end
end
swagger_path '/travel_pay/v0/claims' do
operation :post do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::BadRequestError
key :description, 'Submit a travel reimbursment claim'
key :operationId, 'postTravelPayClaim'
key :tags, %w[travel_pay]
parameter :authorization
parameter do
key :name, :appointmentDateTime
key :in, :body
key :description, 'Appointment local start time'
key :required, true
schema do
property :appointmentDateTime do
key :type, :string
end
end
end
parameter do
key :name, :facilityStationNumber
key :in, :body
key :description, 'Appointment facility ID'
key :required, true
schema do
property :facilityStationNumber do
key :type, :string
end
end
end
parameter do
key :name, :appointmentType
key :in, :body
key :description, 'CompensationAndPensionExamination or Other'
key :required, true
schema do
property :appointmentType do
key :type, :string
end
end
end
parameter do
key :name, :isComplete
key :in, :body
key :description, 'Whether or not appointment is complete'
key :required, true
schema do
property :isComplete do
key :type, :boolean
end
end
end
response 201 do
key :description, 'Successfully submitted claim for a user'
schema do
key :$ref, :TravelPayClaimSummary
end
end
end
end
swagger_path '/travel_pay/v0/claims/{claimId}/documents/{docId}' do
operation :get do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::BadRequestError
extend Swagger::Responses::RecordNotFoundError
key :description, 'Get a document binary'
key :operationId, 'getTravelPayDocumentBinary'
key :tags, %w[travel_pay]
parameter :authorization
parameter do
key :name, 'claimId'
key :in, :path
key :description, 'The non-PII/PHI id of a claim (UUID - any version)'
key :required, true
key :type, :string
end
parameter do
key :name, 'docId'
key :in, :path
key :description, 'The non-PII/PHI id of a document (UUID - any version)'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Successfully retrieved claim details for a user'
schema do
key :$ref, :TravelPayDocumentBinary
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/datadog_action.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class DatadogAction
include Swagger::Blocks
swagger_path '/v0/datadog_action' do
operation :post do
key :summary, 'Record a front-end action in Datadog'
key :operationId, 'recordDatadogAction'
key :tags, ['Telemetry']
parameter do
key :name, :metric
key :in, :body
key :required, true
schema do
key :$ref, :DatadogActionRequest
end
end
response 204 do
key :description, 'No Content'
end
end
end
swagger_component do
schema :DatadogActionRequest do
property :metric do
key :type, :string
end
property :tags do
key :type, :array
items do
key :type, :string
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/search.rb
|
# frozen_string_literal: true
# rubocop:disable Layout/LineLength
module Swagger
module Requests
class Search
include Swagger::Blocks
swagger_path '/v0/search' do
operation :get do
key :description, 'Returns a list of search results, from Search.gov, for the passed search query'
key :operationId, 'getSearchResults'
key :tags, %w[
search
]
parameter do
key :name, 'query'
key :in, :query
key :description, 'The search term being queried'
key :required, true
key :type, :string
end
parameter do
key :name, 'page'
key :in, :query
key :description, 'The page number for the page of results that is being requested'
key :required, false
key :type, :integer
end
response 200 do
key :description, 'Response is OK'
schema do
key :required, %i[data meta]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
key :required, [:body]
property :body, type: :object do
property :query, type: :string, description: 'The term used to generate these search results'
property :web, type: :object do
property :total, type: :integer, description: 'Total number of results available.'
property :next_offset, type: :integer, description: 'Offset for the subsequent results.'
property :spelling_correction,
type: %i[string null],
description: 'Spelling correction for your search term.'
property :results do
key :type, :array
items do
property :title, type: :string
property :url, type: :string
property :snippet, type: :string
property :publication_date, type: %i[string null]
end
end
end
property :text_best_bets do
key :type, :array
key :description, 'Text best bets, which appear only when the query matches the text of the best bet’s title, description, or keywords.'
items do
property :id, type: :integer
property :title, type: :string
property :url, type: :string
property :description, type: :string
end
end
property :graphic_best_bets do
key :type, :array
key :description, 'Graphic best bets, which appear only when the query matches the text of the best bet’s title, description, or keywords.'
items do
property :id, type: :integer
property :title, type: :string
property :title_url, type: :string
property :image_url, type: :string
property :image_alt_text, type: :string
property :links do
key :type, :array
key :description, 'An array of links in the graphic best bet. Each link contains a title and a URL'
items do
property :title, type: :string
property :url, type: :string
end
end
end
end
property :health_topics do
key :type, :array
items do
property :title, type: :string
property :url, type: :string
property :snippet, type: :string
property :related_topics do
key :type, :array
key :description, 'An array of topics related to the health topic. Each topic contains a title and a URL'
items do
property :title, type: :string
property :url, type: :string
end
end
property :related_sites do
key :type, :array
key :description, 'An array of sites related to the the health topic. Each site contains a title and a URL'
items do
property :title, type: :string
property :url, type: :string
end
end
end
end
property :job_openings do
key :type, :array
items do
property :position_title, type: :string
property :organization_name, type: :string
property :rate_interval_code, type: :string
property :minimum, type: :integer, description: 'Minimum salary of the job opening'
property :maximum, type: :integer, description: 'Maximum salary of the job opening'
property :start_date, type: :string
property :end_date, type: :string
property :url, type: :string
property :org_codes, type: :string
property :locations do
key :type, :array
key :description, 'An array of locations of the job opening'
items do
key :type, :string
end
end
property :related_sites do
key :type, :array
items do
property :title, type: :string
property :url, type: :string
end
end
end
end
property :recent_tweets do
key :type, :array
items do
property :text, type: :string
property :url, type: :string
property :name, type: :string
property :snippet, type: :string
property :screen_name, type: :string, description: 'Screen name of the tweet author'
property :profile_image_url, type: :string
end
end
property :recent_news do
key :type, :array
items do
property :title, type: :string
property :url, type: :string
property :snippet, type: :string
property :publication_date, type: :string
property :source, type: :string
end
end
property :recent_video_news do
key :type, :array
items do
property :title, type: :string
property :url, type: :string
property :snippet, type: :string
property :publication_date, type: :string
property :source, type: :string
property :thumbnail_url, type: :string
end
end
property :federal_register_documents do
key :type, :array
items do
property :id, type: :integer
property :document_number, type: :string
property :document_type, type: :string
property :title, type: :string
property :url, type: :string
property :agency_names do
key :type, :array
key :description, 'An array of agency names of the federal register document'
items do
key :type, :string
end
end
property :page_length, type: :integer
property :start_page, type: :integer
property :end_page, type: :integer
property :publication_date, type: :string
property :comments_close_date, type: :string
end
end
property :related_search_terms do
key :type, :array
key :description, 'An array of related search terms, which are based on recent, common searches on the your site.'
items do
key :type, :string
end
end
end
end
end
property :meta do
property :pagination, '$ref': :Pagination
end
end
end
response 400 do
key :description, 'Error Occurred'
schema do
key :$ref, :Errors
end
end
response 429 do
key :description, 'Exceeded rate limit'
schema do
key :required, [:errors]
property :errors do
key :type, :array
items do
key :required, %i[title detail code status source]
property :title, type: :string, example: 'Exceeded rate limit'
property :detail,
type: :string,
example: 'Exceeded Search.gov rate limit'
property :code, type: :string, example: 'SEARCH_429'
property :status, type: :string, example: '429'
property :source, type: :string, example: 'Search::Service'
end
end
end
end
end
end
end
end
end
# rubocop:enable Layout/LineLength
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/caregivers_assistance_claims.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class CaregiversAssistanceClaims
include Swagger::Blocks
swagger_path '/v0/caregivers_assistance_claims' do
operation :post do
extend Swagger::Responses::ValidationError
key :description,
'Submit a 10-10CG form (Application for the Program of Comprehensive Assistance for Family Caregivers)'
key :tags, %w[benefits_forms]
parameter do
key :name, :form
key :in, :body
key :description, 'The application\'s submission data (formatted in compliance with the 10-10CG schema).'
key :required, true
schema do
key :type, :string
end
end
response 200 do
key :description, 'Form Submitted'
schema do
key :required, [:data]
property :data, type: :object do
property :id do
key :description, 'Number of pages contained in the form'
key :type, :string
key :example, ''
end
property :type do
key :description, 'This is always "form1010cg_submissions"'
key :type, :string
key :example, 'form1010cg_submissions'
end
end
end
end
end
end
swagger_path '/v0/caregivers_assistance_claims/facilities' do
operation :post do
key :description, 'Get a list of medical facilities based on search criteria.'
key :tags, %w[benefits_forms]
parameter do
key :name, :zip
key :in, :query
key :description, 'The zip code for facility search.'
key :type, :string
end
parameter do
key :name, :state
key :in, :query
key :description, 'The state for facility search.'
key :type, :string
end
parameter do
key :name, :lat
key :in, :query
key :description, 'The latitude for facility search.'
key :type, :number
end
parameter do
key :name, :long
key :in, :query
key :description, 'The longitude for facility search.'
key :type, :number
end
parameter do
key :name, :radius
key :in, :query
key :description, 'The radius around the location for facility search.'
key :type, :number
end
parameter do
key :name, :page
key :in, :query
key :description, 'The page of results to retrieve.'
key :type, :integer
end
parameter do
key :name, :per_page
key :in, :query
key :description, 'The number of facilities per page.'
key :type, :integer
end
parameter do
key :name, :facilityIds
key :in, :query
key :description, 'Comma-separated list of facility IDs to filter by.'
key :type, :string
end
response 200 do
key :description, 'List of facilities retrieved successfully'
schema do
key :$ref, :Facilities
end
end
end
end
swagger_path '/v0/caregivers_assistance_claims/download_pdf' do
operation :post do
key :description, 'Download a pre-filled 10-10CG PDF form.'
key :tags, %w[benefits_forms]
parameter do
key :name, :claim_id
key :in, :query
key :description, 'The ID of the claim to download the PDF for.'
key :required, true
key :type, :string
end
response 200 do
key :description, 'PDF form download'
schema do
property :data, type: :string, format: 'binary'
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/form1010_ezrs.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class Form1010Ezrs
include Swagger::Blocks
swagger_path '/v0/form1010_ezrs' do
operation :post do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::ValidationError
extend Swagger::Responses::BackendServiceError
extend Swagger::Responses::InternalServerError
key :description, 'Submit a 10-10EZR form'
key :operationId, 'postForm1010Ezr'
key :tags, %w[benefits_forms]
parameter :authorization
parameter do
key :name, :form
key :in, :body
key :description, '10-10EZR form data'
key :required, true
schema do
key :type, :string
end
end
response 200 do
key :description, 'submit 10-10EZR form response'
schema do
key :$ref, :Form1010EzrSubmissionResponse
end
end
end
end
swagger_path '/v0/form1010_ezrs/download_pdf' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Download a pre-filled 10-10EZR PDF form.'
key :operationId, 'postForm1010EzrDownloadPdf'
key :tags, %w[benefits_forms]
parameter :authorization
end
end
swagger_schema :Form1010EzrSubmissionResponse do
key :required, %i[formSubmissionId timestamp success]
property :formSubmissionId, type: %i[integer null], example: nil
property :timestamp, type: %i[string null], example: nil
property :success, type: :boolean
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/forms.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class Forms
include Swagger::Blocks
swagger_path '/v0/forms' do
operation :get do
key :description, 'Returns a list of forms from the VA Lighthouse API, filtered using an optional search term'
key :operationId, 'getForms'
key :tags, %w[
forms
]
parameter do
key :name, 'term'
key :in, :query
key :description, 'Query the form number as well as title'
key :required, false
key :type, :string
end
response 200 do
key :description, 'Successful forms query'
schema do
key :$ref, :Forms
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/in_progress_forms.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class InProgressForms
include Swagger::Blocks
tags = { tags: ['in_progress_forms'] }
swagger_path '/v0/in_progress_forms' do
operation :get, **tags do
extend Swagger::Responses::AuthenticationError
key :description, 'Get Saved Form Summaries'
key :operationId, 'listInProgressForms'
parameter :authorization
response 200 do
key :description, 'get saved form summaries'
schema { key :$ref, :InProgressFormsResponse }
end
end
end
swagger_path '/v0/in_progress_forms/{id}' do
operation :delete, **tags do
extend Swagger::Responses::AuthenticationError
key :description, 'Delete form data'
key :operationId, 'deleteInProgressForm'
parameter :authorization
parameter do
key :name, :id
key :in, :path
key :description, 'ID of the form'
key :required, true
key :type, :string
end
response 200 do
key :description, 'delete form response'
schema { key :$ref, :InProgressFormResponse }
end
end
operation :get, **tags do
extend Swagger::Responses::AuthenticationError
key :description, 'Get form data'
key :operationId, 'getInProgressForm'
parameter :authorization
parameter do
key :name, :id
key :in, :path
key :description, 'ID of the form'
key :required, true
key :type, :string
end
response 200 do
key :description, 'get form response'
schema { key :$ref, :InProgressFormShowResponse }
end
end
operation :put, **tags do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::InternalServerError
key :description, 'Update form data and metadata'
key :operationId, 'updateInProgressForm'
parameter :authorization
parameter do
key :name, :id
key :in, :path
key :description, 'ID of the form'
key :required, true
key :type, :string
end
parameter do
key :name, :payload
key :in, :body
key :description, 'updated form data and metadata. one of "form_data" or "formData" must be present'
key :required, true
schema example: { formData: { lastName: 'Smith' }, metadata: { ver: 1 } } do
property :formData, type: :object, description: '(alias "form_data")'
property :form_data, type: :object, description: '(alias "formData")'
property :metadata, type: :object
end
end
response 200 do
key :description, 'update form response'
schema { key :$ref, :InProgressFormResponse }
end
end
end
swagger_schema :InProgressFormShowResponse do
property :formData, type: :object
property :metadata, type: :object
end
swagger_schema :InProgressFormResponse do
property :data, type: :object do
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
property :formId, type: :string
property :createdAt, type: :string
property :updatedAt, type: :string
property :metadata, type: :object
end
end
end
swagger_schema :InProgressFormsResponse do
property :data, type: :array do
items type: :object do
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
property :formId, type: :string
property :createdAt, type: :string
property :updatedAt, type: :string
property :metadata, type: :object
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/event_bus_gateway.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class EventBusGateway
include Swagger::Blocks
swagger_path '/v0/event_bus_gateway/send_email' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Sends an email to a veteran about an event managed by Event Bus Gateway'
key :operationId, 'sendEmail'
key :tags, %w[event_bus_gateway]
parameter :authorization
parameter do
key :name, :template_id
key :description, 'VA Notify template ID'
key :in, :formData
key :required, true
key :type, :integer
end
response 200 do
key :description, 'Response is OK'
end
response 401 do
key :description, 'Not authorized'
schema do
key :type, :object
property :errors do
key :type, :string
key :example, 'Service Account access token JWT is malformed'
end
end
end
end
end
swagger_path '/v0/event_bus_gateway/send_push' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Sends a push notification to a veteran about an event managed by Event Bus Gateway'
key :operationId, 'sendPush'
key :tags, %w[event_bus_gateway]
parameter :authorization
parameter do
key :name, :template_id
key :description, 'VEText push notification template ID'
key :in, :formData
key :required, true
key :type, :integer
end
response 200 do
key :description, 'Response is OK'
end
response 401 do
key :description, 'Not authorized'
schema do
key :type, :object
property :errors do
key :type, :string
key :example, 'Service Account access token JWT is malformed'
end
end
end
end
end
swagger_path '/v0/event_bus_gateway/send_notifications' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description,
'Sends one email and/or one push notification to a veteran. At least one template ID must be provided.'
key :operationId, 'sendNotifications'
key :tags, %w[event_bus_gateway]
parameter :authorization
parameter do
key :name, :email_template_id
key :description, 'VA Notify email template ID (optional)'
key :in, :formData
key :required, false
key :type, :integer
end
parameter do
key :name, :push_template_id
key :description, 'VEText push notification template ID (optional)'
key :in, :formData
key :required, false
key :type, :integer
end
response 200 do
key :description, 'Response is OK'
end
response 401 do
key :description, 'Not authorized'
schema do
key :type, :object
property :errors do
key :type, :string
key :example, 'Service Account access token JWT is malformed'
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/claim_status.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class ClaimStatus
include Swagger::Blocks
swagger_path '/v0/evss_claims/{evss_claim_id}/documents' do
operation :post do
extend Swagger::Responses::UnprocessableEntityError
key :description, 'upload a document associated with a claim'
key :operationId, 'postDocument'
key :tags, %w[claim_status_tool]
parameter :authorization
parameter do
key :name, :cst_file_upload
key :in, :body
key :description, ''
key :required, true
schema do
key :$ref, :ClaimDocumentInput
end
end
parameter do
key :name, :evss_claim_id
key :description, ''
key :in, :path
key :required, true
key :type, :string
end
response 202 do
key :description, 'Response is Accepted'
schema do
key :required, %i[job_id]
property :job_id, type: :string, example: ''
end
end
end
end
swagger_schema :ClaimDocumentInput do
key :required, %i[file document_type]
property :file do
key :type, :string
end
property :tracked_item_id do
key :type, :string
end
property :password do
key :type, :string
key :example, 'My Password!'
end
property :document_type do
key :type, :string
key :example, 'L023'
key :enum, EVSSClaimDocument::DOCUMENT_TYPES.keys
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/sign_in.rb
|
# frozen_string_literal: true
# rubocop:disable Layout/LineLength
module Swagger
module Requests
class SignIn
include Swagger::Blocks
swagger_path '/v0/sign_in/authorize' do
operation :get do
key :description, 'Initializes Sign in Service authorization & authentication.'
key :operationId, 'getSignInAuthorize'
key :tags, %w[authentication]
key :produces, ['text/html']
key :consumes, ['application/json']
parameter do
key :name, 'type'
key :in, :query
key :description, 'Credential provider selected to authenticate with. Values: `logingov`, `idme`, `mhv`, `dslogon`'
key :required, true
key :type, :string
end
parameter do
key :name, 'client_id'
key :in, :query
key :description, 'Determines cookie (web) vs. API (mobile) authentication. Values: `web`, `mobile`.'
key :required, true
key :type, :string
end
parameter do
key :name, 'acr'
key :in, :query
key :description, 'Level of authentication requested, dependant on CSP. Values: `loa1`, `loa3`, `ial1`, `ial2`, `min`.'
key :required, true
key :type, :string
end
parameter do
key :name, 'code_challenge'
key :in, :query
key :description, 'Value created from a `code_verifier` hex that is hash and encoded.'
key :required, true
key :type, :string
end
parameter do
key :name, 'code_challenge_method'
key :in, :query
key :description, 'Method used to create code_challenge (*must* equal `S256`).'
key :required, true
key :type, :string
end
parameter do
key :name, 'state'
key :in, :query
key :description, 'Client-provided code that is returned to the client upon successful authentication. Minimum length is 22 characters.'
key :required, false
key :type, :string
end
response 200 do
key :description, 'User is redirected to credential service provider via a frontend form submission.'
schema { key :$ref, :CSPAuthFormResponse }
end
end
end
swagger_path '/v0/sign_in/callback' do
operation :get do
key :description, 'Sign in Service authentication callback.'
key :operationId, 'getSignInCallback'
key :tags, %w[authentication]
key :produces, ['text/html']
key :consumes, ['application/json']
parameter do
key :name, 'code'
key :in, :query
key :description, 'Authentication code created by the credential provider & used to obtain tokens from them.'
key :required, true
key :type, :string
end
parameter do
key :name, 'state'
key :in, :query
key :description, 'Encoded payload that includes information passed from vets-api to credential provider in `/authorize` call.'
key :required, true
key :type, :string
end
response 302 do
key :description, 'User object is created in vets-api, then redirected back to client with an authentication code that can be used to obtain tokens. If a `state` param was included in the original `/authorize` request it will be returned here.'
schema do
key :type, :string
key :format, :uri
key :example, 'vamobile://login-success?code=0c2d21d3-465b-4054-8030-1d042da4f667&state=d940a929b7af6daa595707d0c99bec57'
end
end
end
end
swagger_path '/v0/sign_in/token' do
operation :post do
key :description, 'Sign in Service session creation & tokens request.'
key :operationId, 'postSignInToken'
key :tags, %w[authentication]
key :produces, ['application/json']
key :consumes, ['application/json']
parameter do
key :name, 'grant_type'
key :in, :query
key :description, 'Authentication grant type value, must equal `authorization_code`.'
key :required, true
key :type, :string
end
parameter do
key :name, 'code'
key :in, :query
key :description, 'Authentication code passed to the client through the `code` param in authentication `/callback` redirect.'
key :required, true
key :type, :string
end
parameter do
key :name, 'code_verifier'
key :in, :query
key :description, 'Original hex that was hashed and SHA256-encoded to create the `code_challenge` used in the `/authenticate` request.'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Authentication code and code_verifier validated, session and tokens created & tokens returned to client.'
schema { key :$ref, :TokenResponse }
end
end
end
swagger_path '/v0/sign_in/refresh' do
operation :post do
key :description, 'Sign in Service session & tokens refresh.'
key :operationId, 'postSignInRefresh'
key :tags, %w[authentication]
key :produces, ['application/json']
key :consumes, ['application/json']
parameter do
key :name, 'refresh_token'
key :in, :query
key :description, 'Refresh token string.'
key :required, true
key :type, :string
end
parameter do
key :name, 'anti_csrf_token'
key :in, :query
key :description, 'Anti CSRF token, used to match `/refresh` calls with the `token` call that generated the refresh token used - currently disabled, this can be ignored.'
key :required, false
key :type, :string
end
response 200 do
key :description, 'Refresh token validated, session updated, new tokens created and returned to client.'
schema { key :$ref, :TokenResponse }
end
end
end
swagger_path '/v0/sign_in/revoke' do
operation :post do
key :description, 'Sign in Service session destruction.'
key :operationId, 'postSignInRevoke'
key :tags, %w[authentication]
key :produces, ['application/json']
key :consumes, ['application/json']
parameter do
key :name, 'refresh_token'
key :in, :query
key :description, 'Refresh token string, must be URI-encoded.'
key :required, true
key :type, :string
end
parameter do
key :name, 'anti_csrf_token'
key :in, :query
key :description, 'Anti CSRF token, used to match `refresh` calls with the `token` call that generated the refresh token used - currently disabled, this can be ignored.'
key :required, false
key :type, :string
end
response 200 do
key :description, 'Refresh token validated & session destroyed, invalidating connected tokens.'
end
end
end
swagger_path '/v0/sign_in/revoke_all_sessions' do
operation :get do
key :description, 'Sign in Service destruction of all of a user\'s sessions.'
key :operationId, 'getSignInRevokeAll'
key :tags, %w[authentication]
key :produces, ['application/json']
key :consumes, ['application/json']
parameter :optional_authorization
response 200 do
key :description, 'Access token validated & included `user_uuid` used to look up & destroy all of a user\'s sessions.'
schema {}
end
end
end
swagger_path '/v0/sign_in/logout' do
operation :get do
key :description, 'User-initiated logout of their Sign in Service session.'
key :operationId, 'getSignInLogout'
key :tags, %w[authentication]
key :produces, ['application/json']
key :consumes, ['application/json']
parameter :optional_authorization
response 302 do
key :description, 'Access token validated & session destroyed, invalidating connected tokens. User is redirected to credential provider to end their session, then redirect back to VA.gov frontend.'
schema { key :$ref, :LogoutRedirectResponse }
end
end
end
end
end
end
# rubocop:enable Layout/LineLength
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/banners.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class Banners
include Swagger::Blocks
swagger_path '/v0/banners' do
operation :get do
key :description, 'Returns banners that match the specified path and banner type'
key :operationId, 'getBannersByPath'
key :tags, ['banners']
parameter do
key :name, 'path'
key :in, :query
key :description, 'Path to match banners against'
key :required, true
key :type, :string
end
parameter do
key :name, 'type'
key :in, :query
key :description, 'Banner type to filter by (default: "full_width_banner_alert")'
key :required, false
key :type, :string
end
response 200 do
key :description, 'Banners retrieved successfully'
schema do
property :banners do
key :type, :array
items do
property :id, type: :integer
property :entity_bundle, type: :string
property :context do
key :type, :array
items do
property :entity do
property :entityUrl do
property :path, type: :string
end
end
end
end
end
end
property :path, type: :string
property :banner_type, type: :string
end
end
response 422 do
key :description, 'Unprocessable Entity'
schema do
property :error do
key :type, :string
key :example, 'Path parameter is required'
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/form210779.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class Form210779
include Swagger::Blocks
FORM_ID = '21-0779'
swagger_path '/v0/form210779' do
operation :post do
extend Swagger::Responses::BadRequestError
extend Swagger::Responses::RecordNotFoundError
extend Swagger::Responses::SavedForm
extend Swagger::Responses::UnprocessableEntityError
extend Swagger::Responses::ValidationError
key :description,
"Submit a #{FORM_ID} form (Request for Nursing Home Information in Connection with Claim for " \
'Aid and Attendance) - STUB IMPLEMENTATION for frontend development'
key :operationId, 'submitForm210779'
key :tags, %w[benefits_forms]
key :produces, ['application/json']
parameter :optional_authorization
parameter do
key :name, :form
key :in, :body
key :description, "Form #{FORM_ID} submission data"
key :required, true
schema do
VetsJsonSchema::SCHEMAS[FORM_ID]['properties']
end
end
end
end
swagger_path '/v0/form210779/download_pdf/{guid}' do
operation :get do
extend Swagger::Responses::RecordNotFoundError
key :description, "Download the submitted #{FORM_ID} PDF form"
key :operationId, 'downloadForm210779Pdf'
key :tags, %w[benefits_forms]
key :produces, ['application/pdf', 'application/json']
parameter :optional_authorization
parameter do
key :name, 'guid'
key :in, :path
key :description, 'the guid from the form submission response'
key :required, true
key :type, :string
end
response 200 do
key :description, 'PDF file successfully generated and ready for download'
schema do
key :type, :file
end
end
end
end
VetsJsonSchema::SCHEMAS.fetch(FORM_ID)['definitions'].each do |key, value|
swagger_schema(key, value)
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/veteran_readiness_employment_claims.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class VeteranReadinessEmploymentClaims
include Swagger::Blocks
swagger_path '/v0/veteran_readiness_employment_claims' do
operation :post do
extend Swagger::Responses::ValidationError
extend Swagger::Responses::SavedForm
key :description, 'Submit an employment readiness claim (CH31)/28-1900'
key :operationId, 'adVeteranReadinessEmploymentClaim'
key :tags, %w[benefits_forms]
parameter :optional_authorization
parameter do
key :name, :form
key :in, :body
key :description, 'Veteran Readiness Employment Claim form data'
key :required, true
schema do
key :type, :string
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/form1095_bs.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class Form1095Bs
include Swagger::Blocks
swagger_path '/v0/form1095_bs/available_forms' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'List of available 1095-B forms for the user'
key :operationId, 'getAvailable1095BForms'
key :tags, %w[form_1095_b]
parameter :authorization
response 200 do
key :description, 'Successful return of available forms array'
schema do
key :required, %i[available_forms]
property :available_forms, type: :array do
items do
property :year, type: :integer, example: 2021
property :last_updated, type: %i[string null], example: '2022-08-03T16:08:50.071Z'
end
end
end
end
end
end
swagger_path '/v0/form1095_bs/download_txt/{tax_year}' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Download text version of the 1095-B for the given tax year'
key :operationId, 'downloadTextForm1095B'
key :produces, ['text/plain; charset=utf-8']
key :tags, %w[form_1095_b]
parameter :authorization
parameter do
key :name, :tax_year
key :in, :path
key :description, 'Tax year of 1095-B to retrieve'
key :required, true
key :type, :integer
end
response 200 do
key :description, 'Successful production of 1095-B text form'
schema do
key :type, :file
end
end
response 404 do
key :description, "User's 1095-B form not found for given tax-year"
schema do
key :$ref, :Errors
end
end
end
end
swagger_path '/v0/form1095_bs/download_pdf/{tax_year}' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Download PDF version of the 1095-B for the given tax year'
key :operationId, 'downloadPdfForm1095B'
key :produces, ['application/pdf']
key :tags, %w[form_1095_b]
parameter :authorization
parameter do
key :name, :tax_year
key :in, :path
key :description, 'Tax year of 1095-B to retrieve'
key :required, true
key :type, :integer
end
response 200 do
key :description, 'Successful production of 1095-B PDF form'
schema do
key :type, :file
end
end
response 404 do
key :description, "User's 1095-B form not found for given tax-year"
schema do
key :$ref, :Errors
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/benefits_claims.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class BenefitsClaims
include Swagger::Blocks
swagger_path '/v0/benefits_claims/failed_upload_evidence_submissions' do
operation :get do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::ForbiddenError
extend Swagger::Responses::RecordNotFoundError
key :description,
'Get a list of failed evidence submissions for all claims for a user.'
key :operationId, 'getFailedUploadEvidenceSubmissions'
key :tags, %w[benefits_claims]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :type, :object
key :required, [:data]
property :data do
key :type, :array
items do
key :$ref, :FailedEvidenceSubmission
end
end
end
end
response 504 do
key :description, 'Gateway Timeout: Lighthouse failed to respond in a timely manner'
schema '$ref': :Errors
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/dependents_applications.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class DependentsApplications
include Swagger::Blocks
swagger_path '/v0/dependents_applications/show' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Get the dependents for a veteran by participant ID'
key :operationId, 'getDependents'
key :tags, %w[dependents_applications]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :Dependents
end
end
end
end
swagger_path '/v0/dependents_applications' do
operation :post do
extend Swagger::Responses::ValidationError
extend Swagger::Responses::SavedForm
key :description, 'Submit a dependency claim'
key :operationId, 'addDependencyClaim'
key :tags, %w[benefits_forms]
parameter :optional_authorization
parameter do
key :name, :form
key :in, :body
key :description, 'Dependency claim form data'
key :required, true
schema do
key :type, :string
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/feature_toggles.rb
|
# frozen_string_literal: true
require 'backend_services'
module Swagger
module Requests
class FeatureToggles
include Swagger::Blocks
swagger_path '/v0/feature_toggles' do
operation :get do
key :description, 'Gets the current status of feature toggles'
key :operationId, 'getFeatureToggless'
key :tags, %w[site]
parameter :optional_authorization
parameter :features
parameter do
key :name, :cookie_id
key :in, :query
key :description, 'a unique string from the front end so that features can be configured to be "sticky" for
unauthenticated users'
key :required, false
key :type, :string
end
response 200 do
key :description, 'Response is OK'
schema do
key :required, %i[data]
property :data, type: :object do
key :required, %i[features]
property :features, type: :array do
items do
property :name, type: :string, example: 'facility_locator'
property :value, type: :boolean
end
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/profile.rb
|
# frozen_string_literal: true
# rubocop:disable Metrics/ClassLength
# rubocop:disable Layout/LineLength
module Swagger
module Requests
class Profile
include Swagger::Blocks
swagger_path '/v0/profile/direct_deposits' do
operation :get do
key :produces, ['application/json']
key :consumes, ['application/json']
key :description, 'Get a veterans direct deposit information for comp and pen or education benefits'
key :tags, %w[
profile
]
parameter :authorization
response 200 do
key :description, 'Direct deposit information for a users comp and pen or education benefits.'
schema do
key :type, :object
property(:data) do
key :type, :object
property :id, type: :string
property :type, type: :string
property :attributes do
key :type, :object
property :control_information do
key :required, %i[
can_update_direct_deposit
is_corp_available
is_edu_claim_available
has_cp_claim
has_cp_award
is_corp_rec_found
has_no_bdn_payments
has_index
is_competent
has_mailing_address
has_no_fiduciary_assigned
is_not_deceased
has_payment_address
has_identity
]
property :can_update_direct_deposit, type: :boolean, example: true, description: 'Must be true to view payment account information'
property :is_corp_available, type: :boolean, example: true, description: ''
property :is_edu_claim_available, type: :boolean, example: true, description: 'Is true if education claim'
property :has_cp_claim, type: :boolean, example: true, description: 'Is true if comp and pen claim'
property :has_cp_award, type: :boolean, example: true, description: 'Is true if comp and pen award'
property :is_corp_rec_found, type: :boolean, example: true, description: ''
property :has_no_bdn_payments, type: :boolean, example: true, description: ''
property :has_index, type: :boolean, example: true, description: ''
property :is_competent, type: :boolean, example: true, description: ''
property :has_mailing_address, type: :boolean, example: true, description: ''
property :has_no_fiduciary_assigned, type: :boolean, example: true, description: ''
property :is_not_deceased, type: :boolean, example: true, description: ''
property :has_payment_address, type: :boolean, example: true, description: ''
property :has_identity, type: :boolean, example: true, description: ''
end
property :payment_account do
key :required, %i[
name
account_type
account_number
routing_number
]
property :name, type: :string, example: 'WELLS FARGO BANK', description: 'Bank name'
property :account_type, type: :string, enum: %w[Checking Savings], example: 'Checking', description: 'Bank account type'
property :account_number, type: :string, example: '******7890', description: 'Bank account number (masked)'
property :routing_number, type: :string, example: '*****0503', description: 'Bank routing number (masked)'
end
end
end
end
end
response 400 do
key :description, 'Bad Request'
schema do
key :required, [:errors]
property :errors do
key :type, :array
items do
key :required, %i[title detail code source]
property :title, type: :string,
example: 'Invalid field value',
description: 'Error title'
property :detail, type: :string,
example: 'getDirectDeposit.icn size must be between 17 and 17, getDirectDeposit.icn must match \"^\\d{10}V\\d{6}$\"',
description: 'Description of error (optional)'
property :code, type: :string,
example: 'direct.deposit.icn.invalid',
description: 'Service name with code appended'
property :source, type: %i[string object],
example: 'Lighthouse Direct Deposit',
description: 'Service name'
end
end
end
end
response 401 do
key :description, 'Not authorized'
schema do
key :required, [:errors]
property :errors do
key :type, :array
items do
key :required, %i[title detail code source]
property :title, type: :string, example: 'Invalid token.', description: 'Error title'
property :detail, type: %i[string null], description: 'Description of error (optional)'
property :code, type: :string, example: 'direct.deposit.invalid.token',
description: 'Error code'
property :source, type: %i[string object], example: 'Lighthouse Direct Deposit',
description: 'Service name'
end
end
end
end
response 404 do
key :description, 'Not found'
schema do
key :required, [:errors]
property :errors do
key :type, :array
items do
key :required, %i[title detail code source]
property :title, type: :string, example: 'Person for ICN not found', description: 'Error title'
property :detail, type: :string, example: 'No data found for ICN', description: 'Description of error (optional)'
property :code, type: :string, example: 'direct.deposit.icn.not.found',
description: 'Service name with code appended'
property :source, type: %i[string object], example: 'Lighthouse Direct Deposit',
description: 'Service name'
end
end
end
end
end
operation :put do
key :produces, ['application/json']
key :consumes, ['application/json']
key :description, 'Update a veterans direct deposit information for comp and pen or education benefits'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes to update a payment account.'
key :required, true
schema do
property :payment_account, type: :object do
property :account_number, type: :string, example: '1234567890'
property :account_type, type: :string, example: 'Checking'
property :routing_number, type: :string, example: '031000503'
end
end
end
response 200 do
key :description, 'Direct deposit information for a users comp and pen or education benefits.'
schema do
key :type, :object
property(:data) do
key :type, :object
property :id, type: :string
property :type, type: :string
property :attributes do
key :type, :object
property :control_information do
key :required, %i[
can_update_direct_deposit
is_corp_available
is_edu_claim_available
has_cp_claim
has_cp_award
is_corp_rec_found
has_no_bdn_payments
has_index
is_competent
has_mailing_address
has_no_fiduciary_assigned
is_not_deceased
has_payment_address
has_identity
]
property :can_update_direct_deposit, type: :boolean, example: true, description: 'Must be true to view payment account information'
property :is_corp_available, type: :boolean, example: true, description: ''
property :is_edu_claim_available, type: :boolean, example: true, description: 'Is true if education claim'
property :has_cp_claim, type: :boolean, example: true, description: 'Is true if comp and pen claim'
property :has_cp_award, type: :boolean, example: true, description: 'Is true if comp and pen award'
property :is_corp_rec_found, type: :boolean, example: true, description: ''
property :has_no_bdn_payments, type: :boolean, example: true, description: ''
property :has_index, type: :boolean, example: true, description: ''
property :is_competent, type: :boolean, example: true, description: ''
property :has_mailing_address, type: :boolean, example: true, description: ''
property :has_no_fiduciary_assigned, type: :boolean, example: true, description: ''
property :is_not_deceased, type: :boolean, example: true, description: ''
property :has_payment_address, type: :boolean, example: true, description: ''
property :has_identity, type: :boolean, example: true, description: ''
end
property :payment_account do
key :required, %i[
name
account_type
account_number
routing_number
]
property :name, type: :string, example: 'WELLS FARGO BANK', description: 'Bank name'
property :account_type, type: :string, enum: %w[Checking Savings], example: 'Checking', description: 'Bank account type'
property :account_number, type: :string, example: '******7890', description: 'Bank account number (masked)'
property :routing_number, type: :string, example: '*****0503', description: 'Bank routing number (masked)'
end
end
end
end
end
response 400 do
key :description, 'Routing number related to fraud'
schema do
key :required, [:errors]
property :errors do
key :type, :array
items do
key :required, %i[title detail code source]
property :title, type: :string, example: 'Bad Request', description: 'Error title'
property :detail, type: :string, example: 'Routing number related to potential fraud', description: 'Description of error (optional)'
property :code, type: :string, example: 'direct.deposit.routing.number.fraud.message', description: 'Service name with code appended'
property :source, type: %i[string object], example: 'Lighthouse Direct Deposit', description: 'Service name'
end
end
end
end
end
end
swagger_path '/v0/profile/communication_preferences/{communication_permission_id}' do
operation :patch do
extend Swagger::Responses::AuthenticationError
key :description, 'Update a communication permission'
key :operationId, 'updateCommunicationPreference'
key :tags, %w[
profile
]
parameter :authorization
key :produces, ['application/json']
key :consumes, ['application/json']
extend Swagger::Schemas::Vet360::CommunicationPermission
end
end
swagger_path '/v0/profile/communication_preferences' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Create a communication permission'
key :operationId, 'createCommunicationPreference'
key :tags, %w[
profile
]
parameter :authorization
key :produces, ['application/json']
key :consumes, ['application/json']
extend Swagger::Schemas::Vet360::CommunicationPermission
end
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, "Get user's communication preferences data"
key :operationId, 'getCommunicationPreferences'
key :tags, %w[
profile
]
parameter :authorization
key :produces, ['application/json']
key :consumes, ['application/json']
response 200 do
key :description, 'Communication preferences data'
schema do
key :type, :object
property(:data) do
key :type, :object
property :id, type: :string
property :type, type: :string
property :attributes do
key :type, :object
property :communication_groups do
key :type, :array
items do
key :type, :object
property :id, type: :integer
property :name, type: :string
property :description, type: :string
property :communication_items do
key :type, :array
items do
key :type, :object
property :id, type: :integer
property :name, type: :string
property :communication_channels do
key :type, :array
items do
property :id, type: :integer
property :name, type: :string
property :description, type: :string
property :default_send_indicator, type: :boolean
property :communication_permission do
key :type, :object
property :id, type: :integer
property :allowed, type: :boolean
end
end
end
end
end
end
end
end
end
end
end
end
end
swagger_path '/v0/profile/address_validation' do
operation :post do
key :description, 'Outputs address suggestions'
key :operationId, 'postVet360AddressValidation'
key :tags, %w[
profile
]
parameter :authorization
key :produces, ['application/json']
key :consumes, ['application/json']
parameter do
key :name, :address
key :in, :body
key :description, 'Address input'
key :required, true
schema do
key :type, :object
key :required, [:address]
property(:address) do
key :$ref, :Vet360AddressSuggestion
key :required, %i[
address_pou
]
end
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :type, :object
property(:addresses) do
key :type, :array
items do
key :type, :object
property(:address) do
key :$ref, :Vet360AddressSuggestion
end
property(:address_meta_data) do
key :type, :object
property(:confidence_score, type: :number)
property(:address_type, type: :string)
property(:delivery_point_validation, type: :string)
property(:residential_delivery_indicator, type: :string)
end
end
end
end
end
end
end
swagger_path '/v0/profile/addresses/create_or_update' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, "Create or updates a user's VA profile address"
key :operationId, 'changeVaProfileAddress'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :domestic_body
key :in, :body
key :description, 'Attributes to create a domestic address.'
key :required, true
schema do
key :$ref, :PostVet360DomesticAddress
end
end
parameter do
key :name, :international_body
key :in, :body
key :description, 'Attributes to create an international address.'
key :required, true
schema do
key :$ref, :PostVet360InternationalAddress
end
end
parameter do
key :name, :military_overseas_body
key :in, :body
key :description, 'Attributes to create a military overseas address.'
key :required, true
schema do
key :$ref, :PostVet360MilitaryOverseasAddress
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
end
swagger_path '/v0/profile/addresses' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Creates a users Vet360 address'
key :operationId, 'postVet360Address'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :domestic_body
key :in, :body
key :description, 'Attributes to create a domestic address.'
key :required, true
schema do
key :$ref, :PostVet360DomesticAddress
end
end
parameter do
key :name, :international_body
key :in, :body
key :description, 'Attributes to create an international address.'
key :required, true
schema do
key :$ref, :PostVet360InternationalAddress
end
end
parameter do
key :name, :military_overseas_body
key :in, :body
key :description, 'Attributes to create a military overseas address.'
key :required, true
schema do
key :$ref, :PostVet360MilitaryOverseasAddress
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
operation :put do
extend Swagger::Responses::AuthenticationError
key :description, 'Updates a users existing Vet360 address'
key :operationId, 'putVet360Address'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :domestic_body
key :in, :body
key :description, 'Attributes to update a domestic address.'
key :required, true
schema do
key :$ref, :PutVet360DomesticAddress
end
end
parameter do
key :name, :international_body
key :in, :body
key :description, 'Attributes to update an international address.'
key :required, true
schema do
key :$ref, :PutVet360InternationalAddress
end
end
parameter do
key :name, :military_overseas_body
key :in, :body
key :description, 'Attributes to update a military overseas address.'
key :required, true
schema do
key :$ref, :PutVet360MilitaryOverseasAddress
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
operation :delete do
extend Swagger::Responses::AuthenticationError
key :description, 'Logically deletes a user\'s existing Vet360 address'
key :operationId, 'deleteVet360Address'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :domestic_body
key :in, :body
key :description, 'Attributes of the domestic address.'
key :required, true
schema do
key :$ref, :PutVet360DomesticAddress
end
end
parameter do
key :name, :international_body
key :in, :body
key :description, 'Attributes of the international address.'
key :required, true
schema do
key :$ref, :PutVet360InternationalAddress
end
end
parameter do
key :name, :military_overseas_body
key :in, :body
key :description, 'Attributes of the military overseas address.'
key :required, true
schema do
key :$ref, :PutVet360MilitaryOverseasAddress
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
end
swagger_path '/v0/profile/email_addresses/create_or_update' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Create or update a users VA profile email address'
key :operationId, 'changeVaProfileEmailAddress'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes to create an email address.'
key :required, true
schema do
key :$ref, :PostVet360Email
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
end
swagger_path '/v0/profile/email_addresses' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Creates a users Vet360 email address'
key :operationId, 'postVet360EmailAddress'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes to create an email address.'
key :required, true
schema do
key :$ref, :PostVet360Email
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
operation :put do
extend Swagger::Responses::AuthenticationError
key :description, 'Updates a users existing Vet360 email address'
key :operationId, 'putVet360EmailAddress'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes to update an email address.'
key :required, true
schema do
key :$ref, :PutVet360Email
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
operation :delete do
extend Swagger::Responses::AuthenticationError
key :description, 'Deletes a users existing Vet360 email address'
key :operationId, 'deleteVet360EmailAddress'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes of an email address.'
key :required, true
schema do
key :$ref, :PutVet360Email
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
end
swagger_path '/v0/profile/full_name' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Gets a users full name with suffix'
key :operationId, 'getFullName'
key :tags, %w[
profile
]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
property :first, type: :string, example: 'Jack'
property :middle, type: :string, example: 'Robert'
property :last, type: :string, example: 'Smith'
property :suffix, type: :string, example: 'Jr.'
end
end
end
end
end
end
swagger_path '/v0/profile/initialize_vet360_id' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Initializes a vet360_id for the current user'
key :operationId, 'initializeVet360Id'
key :tags, %w[
profile
]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
end
swagger_path '/v0/profile/person/status/{transaction_id}' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Gets an updated person transaction by ID'
key :operationId, 'getPersonTransactionStatusById'
key :tags, %w[profile]
parameter :authorization
parameter do
key :name, :transaction_id
key :in, :path
key :description, 'ID of transaction'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
end
swagger_path '/v0/profile/personal_information' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Gets a users gender, birth date, preferred name, and gender identity'
key :operationId, 'getPersonalInformation'
key :tags, %w[
profile
]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
property :gender, type: :string, example: 'M'
property :birth_date, type: :string, format: :date, example: '1949-03-04'
property :preferred_name, type: :string, example: 'Pat'
property :gender_identity, type: :object do
property :code, type: :string, example: 'F'
property :name, type: :string, example: 'Female'
end
end
end
end
end
response 502 do
key :description, 'Unexpected response body'
schema do
key :required, [:errors]
property :errors do
key :type, :array
items do
key :required, %i[title detail code status source]
property :title, type: :string, example: 'Unexpected response body'
property :detail,
type: :string,
example: 'MVI service responded without a birthday or a gender.'
property :code, type: :string, example: 'MVI_BD502'
property :status, type: :string, example: '502'
property :source, type: :string, example: 'V0::Profile::PersonalInformationsController'
end
end
end
end
end
end
swagger_path '/v0/profile/service_history' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Gets a collection of a users military service episodes'
key :operationId, 'getServiceHistory'
key :tags, %w[
profile
]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :required, [:data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
key :required, [:service_history]
property :service_history do
key :type, :array
items do
key :required, %i[branch_of_service begin_date]
property :service_type, type: :string, example: 'Military Service'
property :branch_of_service, type: :string, example: 'Air Force'
property :begin_date, type: :string, format: :date, example: '2007-04-01'
property :end_date, type: :string, format: :date, example: '2016-06-01'
property :termination_reason_code, type: :string, example: 'S', description: 'S = Separation From Personnel Category, C = Completion of Active Service Period, D = Death while in personnel category or organization, W = Not Applicable'
property :termination_reason_text, type: :string, example: 'Separation from personnel category or organization'
property :period_of_service_type_code, type: :string, example: 'V', description: 'Service type code'
property :period_of_service_type_text, type: :string, example: 'Reserve member', description: 'Service type text'
property :character_of_discharge_code, type: :string, example: 'DVN', description: 'The abbreviated code used to reference the status of a Servicemember upon termination of an episode'
end
end
property :vet_status_eligibility do
key :type, :object
items do
property :confirmed, type: :boolean
property :message, type: :array
end
end
end
end
end
end
response 400 do
key :description, '_CUF_UNEXPECTED_ERROR'
schema do
key :required, [:errors]
property :errors do
key :type, :array
items do
key :required, %i[title detail code status source]
property :title, type: :string, example: '_CUF_UNEXPECTED_ERROR'
property :detail,
type: :string,
example: 'there was an error encountered processing the Request. Please retry. If problem persists, please contact support with a copy of the Response.'
property :code, type: :string, example: 'CORE100'
property :status, type: :string, example: '400'
property :source, type: :string, example: 'V0::Profile::ServiceHistoriesController'
end
end
end
end
end
end
swagger_path '/v0/profile/status/{transaction_id}' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Gets an updated transaction by ID'
key :operationId, 'getTransactionStatusById'
key :tags, %w[profile]
parameter :authorization
parameter do
key :name, :transaction_id
key :in, :path
key :description, 'ID of transaction'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
end
swagger_path '/v0/profile/status/' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Gets the most recent transactions for a user.' \
' Response will include an array of transactions that are still in progress,' \
' or that were just updated to COMPLETED during the course of this request.' \
' The array will be empty if no transactions are pending or updated.' \
' Only the most recent transaction for each profile field will be included' \
' so there may be up to 4 (Address, Email, Telephone, Permission).'
key :operationId, 'getTransactionStatusesByUser'
key :tags, %w[profile]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionsVet360
end
end
end
end
swagger_path '/v0/profile/telephones/create_or_update' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Create or update a users VA profile telephone'
key :operationId, 'changeVaProfileTelephone'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes to create a telephone.'
key :required, true
schema do
key :$ref, :PostVet360Telephone
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
end
swagger_path '/v0/profile/telephones' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Creates a users Vet360 telephone'
key :operationId, 'postVet360Telephone'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes to create a telephone.'
key :required, true
schema do
key :$ref, :PostVet360Telephone
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
operation :put do
extend Swagger::Responses::AuthenticationError
key :description, 'Updates a users existing telephone'
key :operationId, 'putVet360Telephone'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes to update a telephone'
key :required, true
schema do
key :$ref, :PutVet360Telephone
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
operation :delete do
extend Swagger::Responses::AuthenticationError
key :description, 'Deletes an existing telephone'
key :operationId, 'deleteVet360Telephone'
key :tags, %w[
profile
]
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes of a telephone'
key :required, true
schema do
key :$ref, :PutVet360Telephone
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :AsyncTransactionVet360
end
end
end
end
swagger_path '/v0/profile/connected_applications' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'GET OAuth Applications'
key :operationId, 'getConnectedApplications'
key :tags, ['profile']
parameter :authorization
response 200 do
key :description, 'List of OAuth applications you have connected'
schema do
key :$ref, :ConnectedApplications
end
end
end
end
swagger_path '/v0/profile/connected_applications/{application_id}' do
operation :delete do
extend Swagger::Responses::AuthenticationError
key :description, 'Delete grants for OAuth Applications'
key :operationId, 'deleteConnectedApplications'
key :tags, ['profile']
parameter :authorization
parameter do
key :name, :application_id
key :in, :path
key :description, 'ID of application'
key :required, true
key :type, :string
end
response 204, description: "the connected application's grant have been deleted"
end
end
swagger_path '/v0/profile/valid_va_file_number' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'GET returns true false if veteran has a VA file number'
key :operationId, 'getValidVAFileNumber'
key :tags, ['profile']
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :ValidVAFileNumber
end
end
end
end
swagger_path '/v0/profile/payment_history' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'GET returns two arrays. One is payments made, the other is payments returned'
key :operationId, 'getPaymentHistory'
key :tags, ['profile']
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :PaymentHistory
end
end
end
end
swagger_path '/v0/profile/preferred_names' do
operation :put do
extend Swagger::Responses::AuthenticationError
key :description, 'Adds or updates a users preferred name'
key :operationId, 'putPreferredName'
key :tags, ['profile']
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes to update a users preferred name'
key :required, false
schema do
key :$ref, :PutPreferredName
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :PreferredName
end
end
end
end
swagger_path '/v0/profile/gender_identities' do
operation :put do
extend Swagger::Responses::AuthenticationError
key :description, 'Adds or updates a users gender identity'
key :operationId, 'putGenderIdentity'
key :tags, ['profile']
parameter :authorization
parameter do
key :name, :body
key :in, :body
key :description, 'Attributes to update a users gender identity'
key :required, false
schema do
key :$ref, :PutGenderIdentity
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :GenderIdentity
end
end
end
end
swagger_path '/v0/profile/contacts' do
operation :get do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::ForbiddenError
key :description, "Returns a Veteran's Next-of-Kin and Emergency Contacts"
key :tags, [:profile]
parameter :authorization
response 200 do
key :description, 'Successful request'
schema do
key :$ref, :Contacts
end
end
end
end
swagger_path '/v0/profile/vet_verification_status' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Indicates whether an individual is "Confirmed" or "Not Confirmed" as a Title 38 Veteran according to VA.'
key :tags, [:profile]
parameter :authorization
response 200 do
key :description, 'Confirmation status successfully retrieved.'
schema do
key :type, :object
property(:data) do
key :type, :object
property :id, type: :string
property :type, type: :string
property :attributes do
key :type, :object
property :veteran_status, type: :string, example: 'not confirmed', description: "Veteran's Title 38 status"
property :not_confirmed_reason, type: :string, example: 'PERSON_NOT_FOUND', description: 'Reason for not being confirmed'
property :message, type: :array, example: "We're sorry. There's a problem...", description: 'Alert message to display to user'
end
end
end
end
end
end
end
end
end
# rubocop:enable Metrics/ClassLength
# rubocop:enable Layout/LineLength
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/debts.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class Debts
include Swagger::Blocks
swagger_path '/v0/debts' do
operation :get do
key :description, 'Provides an array of debt details provided by the Debt Management Center for the veteran.'
key :operationId, 'getDebts'
key :tags, %w[debts]
parameter do
key :name, :count_only
key :in, :query
key :description, 'When true, returns only the count of debts'
key :required, false
key :type, :boolean
end
response 200 do
key :description, 'Successful debts lookup'
schema do
property :debtsCount, type: :integer,
description: 'Total number of debts (only returned when count_only=true)'
property :has_dependent_debts, type: :boolean
property :debts, type: :array do
items do
property :file_number, type: :string
property :payee_number, type: :string
property :person_entitled, type: :string
property :deduction_code, type: :string
property :benefit_type, type: :string
property :amount_overpaid, type: :string
property :amount_withheld, type: :string
property :debt_history, type: :array do
items do
property :date, type: :string
property :letter_code, type: :string
property :status, type: :string
property :description, type: :string
end
end
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/debt_letters.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class DebtLetters
include Swagger::Blocks
swagger_path '/v0/debt_letters/{id}' do
operation :get do
key :description, 'Download a debt letter PDF'
key :operationId, 'getDebtLetter'
key :tags, %w[debts]
parameter do
key :name, :id
key :in, :path
key :description, 'Document ID of debt letter'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Debt letter download'
schema do
property :data, type: :string, format: 'binary'
end
end
end
end
swagger_path '/v0/debt_letters' do
operation :get do
key :description, 'Provides an array of debt letter ids and descriptions collected from eFolder'
key :operationId, 'getDebtLetters'
key :tags, %w[debts]
response 200 do
key :description, 'Successful debt letters lookup'
schema do
items do
property :document_id, type: :string
property :doc_type, type: :string
property :type_description, type: :string
property :received_at, type: :string, format: 'date'
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/search_click_tracking.rb
|
# frozen_string_literal: true
# rubocop:disable Layout/LineLength
module Swagger
module Requests
class SearchClickTracking
include Swagger::Blocks
swagger_path '/v0/search_click_tracking/?position={position}&query={query}&url={url}&module_code={module_code}&user_agent={user_agent}' do
operation :post do
key :description, 'Sends a Click Tracking event to Search.gov analytics'
key :operationId, 'sendClickTrackingData'
key :tags, %w[
search_click_tracking
]
parameter do
key :name, 'url'
key :in, :path
key :description, 'the url of the link that was clicked'
key :required, true
key :type, :string
end
parameter do
key :name, 'query'
key :in, :path
key :description, 'the search query used to generate results'
key :required, true
key :type, :string
end
parameter do
key :name, 'position'
key :in, :path
key :description, 'The position/rank of the result on your search results page. Was it the first result or the second?'
key :required, true
key :type, :integer
end
parameter do
key :name, 'user_agent'
key :in, :path
key :description, 'the user agent of the user who clicked'
key :required, true
key :type, :string
end
parameter do
key :name, 'module_code'
key :in, :path
key :description, 'I14Y for web urls, BOOS for best bets, defaults to I14Y'
key :required, true
key :type, :string
end
response 204 do
key :description, 'Empty Response'
end
response 400 do
key :description, 'Error Occurred'
schema do
key :$ref, :Errors
end
end
end
end
end
end
end
# rubocop:enable Layout/LineLength
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/terms_of_use_agreements.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class TermsOfUseAgreements
include Swagger::Blocks
swagger_path '/v0/terms_of_use_agreements/{version}/accept' do
operation :post do
key :description, 'Accepts the terms of use agreement'
key :operationId, 'acceptTermsOfUseAgreement'
key :tags, [
'terms_of_use_agreements'
]
parameter do
key :name, :version
key :in, :path
key :description, 'Version of the terms of use agreement'
key :required, true
key :type, :string
end
response 201 do
key :description, 'accept terms of use agreement response'
schema do
key :$ref, :TermsOfUseAgreement
end
end
response 422 do
key :description, 'unprocessable entity response'
schema do
key :$ref, :Errors
end
end
end
end
swagger_path '/v0/terms_of_use_agreements/{version}/decline' do
operation :post do
key :description, 'Declines the terms of use agreement'
key :operationId, 'declineTermsOfUseAgreement'
key :tags, [
'terms_of_use_agreements'
]
parameter do
key :name, :version
key :in, :path
key :description, 'Version of the terms of use agreement'
key :required, true
key :type, :string
end
response 201 do
key :description, 'decline terms of use agreement response'
schema do
key :$ref, :TermsOfUseAgreement
end
end
response 422 do
key :description, 'unprocessable entity response'
schema do
key :$ref, :Errors
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/coe.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class Coe
include Swagger::Blocks
swagger_path '/v0/coe/status' do
operation :get do
key :description, 'Returns the status of a vet\'s Certificate of Eligibility application.'
key :operationId, 'coeGetCoeStatus'
key :tags, %w[coe]
parameter :authorization
response 200 do
key :description, 'Response is OK. Possible statuses:
- ELIGIBLE: vet is automatically enrolled in a COE.
- UNABLE_TO_DETERMINE_AUTOMATICALLY: vet must complete the COE form.
- AVAILABLE: vet has filled out the COE form and it is available for download.
- DENIED: means that the vet submitted a COE form but it was denied.
- PENDING: vet submitted a COE form but it is still being reviewed.
- PENDING_UPLOAD: vet submitted a COE form but must upload more supporting documents to be granted a COE.
A reference_number is always returned.
An application_create_date is returned unless the COE application is ELIGIBLE or PENDING.
'
schema do
property :data do
property :attributes do
property :status, type: :string, enum: %w[
ELIGIBLE
UNABLE_TO_DETERMINE_AUTOMATICALLY
AVAILABLE
DENIED
PENDING
PENDING_UPLOAD
], example: 'UNABLE_TO_DETERMINE_AUTOMATICALLY'
property :referenceNumber, type: :string, example: '17923279'
property :applicationCreateDate, type: :integer, example: 1_668_447_149_000
end
end
end
end
end
end
swagger_path '/v0/coe/download_coe' do
operation :get do
key :description, 'Downloads Certificate of Eligiblity application as PDF'
key :operationId, 'coeDownloadCoe'
key :tags, %w[coe]
key :produces, ['application/pdf']
parameter :authorization
response 200 do
key :description, 'Response is OK.'
end
end
end
swagger_path '/v0/coe/documents' do
operation :get do
key :description, %(Retrieves a list of supporting documents that the
vet attached to their COE application. The `id` is used to fetch documents
via the `/vo/coe/document_download/{id}` endpoint below. The `mimeType`
is, unfortunately, the filename from which the front end pulls the file
extension. The `documentType` will either be "Veteran Correspondence"
(meaning, a document uploaded by the veteran during the COE form) or
the "kind" of notification letter (e.g. "COE Application First Returned").
By the time you read this, the `description` will probably be a description
of any "Veteran Correspondence." Notification letters should not have a
`description`.
).gsub("\n", ' ')
key :operationId, 'coeDocuments'
key :tags, %w[coe]
parameter :authorization
response 200 do
key :description, 'Response is OK.'
schema do
property :data do
property :attributes do
key :type, :array
items do
key :type, :object
property :id, type: :integer, example: 23_924_541
property :documentType, type: :string, example: 'COE Application First Returned'
property :description, type: [:string, 'null'], example: 'null'
property :mimeType, type: :string, example: 'COE Application First Returned.pdf'
property :createDate, type: :integer, example: 1_664_222_568_000
end
end
end
end
end
end
end
swagger_path '/v0/coe/document_download/{id}' do
operation :get do
key :description, 'Downloads supporting document with specified ID.'
key :operationId, 'coeDocumentDownload'
key :tags, %w[coe]
key :produces, ['application/pdf']
parameter :authorization
parameter do
key :name, :id
key :in, :path
key :description, 'The ID of the supporting document.'
key :required, true
key :type, :integer
end
response 200 do
key :description, 'Response is OK.'
end
end
end
swagger_path '/v0/coe/submit_coe_claim' do
operation :post do
key :description, 'Saves form data and submits it to LGY.'
key :operationId, 'coeSubmitCoeClaim'
key :tags, %w[coe]
parameter :authorization
parameter do
key :name, :lgy_coe_claim
key :in, :body
key :description, 'Form data as a json string.'
key :required, true
schema do
property :lgy_coe_claim do
property :form do
key :type, :string
end
end
example do
key :form, {
'files' =>
[{
'name' => 'Example.pdf',
'size' => 60_217,
'confirmationCode' => 'a7b6004e-9a61-4e94-b126-518ec9ec9ad0',
'isEncrypted' => false,
'attachmentType' => 'Discharge or separation papers (DD214)'
}],
'relevantPriorLoans' => [{
'dateRange' => {
'from' => '2002-05-01T00:00:00.000Z',
'to' => '2003-01-01T00:00:00.000Z'
},
'propertyAddress' => {
'propertyAddress1' => '123 Faker St',
'propertyAddress2' => '2',
'propertyCity' => 'Fake City',
'propertyState' => 'AL',
'propertyZip' => '11111'
},
'vaLoanNumber' => '111222333444',
'propertyOwned' => true,
'intent' => 'ONETIMERESTORATION'
}],
'vaLoanIndicator' => true,
'periodsOfService' => [{
'serviceBranch' => 'Air National Guard',
'dateRange' => {
'from' => '2001-01-01T00:00:00.000Z',
'to' => '2002-02-02T00:00:00.000Z'
}
}],
'identity' => 'ADSM',
'contactPhone' => '2222222222',
'contactEmail' => 'veteran@example.com',
'applicantAddress' => {
'country' => 'USA',
'street' => '140 FAKER ST',
'street2' => '2',
'city' => 'FAKE CITY',
'state' => 'MT',
'postalCode' => '80129'
},
'fullName' => {
'first' => 'Alexander',
'middle' => 'Guy',
'last' => 'Cook',
'suffix' => 'Jr.'
},
'dateOfBirth' => '1950-01-01',
'privacyAgreementAccepted' => true
}.to_json
end
end
end
response 200 do
key :description, 'Form submitted successfully.'
schema do
property :data do
property :attributes do
property :claim do
property :createdAt, type: :string, format: :'date-time'
property :encryptedKmsKey, type: :string
property :formId, type: :string
property :guid, type: :string, format: :uuid
property :id, type: :integer
property :updatedAt, type: :string, format: :'date-time'
property :verifiedDecryptableAt, type: :string, format: :'date-time'
end
property :referenceNumber
end
end
end
end
end
end
swagger_path '/v0/coe/document_upload' do
operation :post do
key :description, 'Upload supporting documents'
key :operationId, 'coeDocumentUpload'
key :tags, %w[coe]
key :consumes, %w[multipart/form-data]
parameter :authorization
parameter do
key :name, :files
key :in, :body
key :description, 'File data'
key :required, true
schema do
key :type, :array
items do
key :type, :object
property :file, type: :string, format: :binary, example: '(binary)'
property :document_type, type: :string, example: 'VA home loan documents'
property :file_type, type: :string, example: 'pdf'
property :file_name, type: :string, example: 'example.pdf'
end
end
end
response 200 do
key :description, 'Files uploaded successfully'
end
response 500 do
key :description, 'Files failed uploading'
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/intent_to_file.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class IntentToFile
include Swagger::Blocks
swagger_path '/v0/intent_to_file' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Get a list of all Intent To File requests made by the veteran'
key :operationId, 'getIntentToFile'
key :tags, %w[form_526 intent_to_file]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :IntentToFiles
end
end
end
end
swagger_path '/v0/intent_to_file/{itf_type}' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Get a list of the Intent To File requests with the specified type made by the veteran'
key :operationId, 'getIntentToFile'
key :tags, %w[intent_to_file]
parameter :authorization
parameter do
key :name, :itf_type
key :in, :path
key :description, 'ITF type. Allowed values: compensation pension survivor'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :IntentToFiles
end
end
end
end
swagger_path '/v0/intent_to_file/{itf_type}' do
operation :post do
extend Swagger::Responses::AuthenticationError
key :description, 'Creates a new Intent To File for the veteran'
key :operationId, 'postIntentToFile'
key :tags, %w[form_526 intent_to_file]
parameter :authorization
parameter do
key :name, :itf_type
key :in, :path
key :description, 'ITF type. Allowed values: compensation pension survivor'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :IntentToFile
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/benefits_reference_data.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class BenefitsReferenceData
include Swagger::Blocks
swagger_path '/v0/benefits_reference_data/{path}' do
operation :get do
key :description,
'Get data from the Lighthouse Benefits Reference Data (BRD) End-point.'
key :operationId, 'getBenefitsReferenceData'
key :tags, %w[benefits_reference_data]
parameter :optional_authorization
parameter do
key :name, :path
key :in, :path
key :description, 'The path/end-point to get data from the Lighthouse Benefits Reference Data (BRD) api'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Response is OK'
schema do
key :required, %i[totalItems totalPages links items]
property :totalItems, type: :integer
property :totalPages, type: :integer
property :links, type: :array
property :items, type: :array
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/upload_supporting_evidence.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class UploadSupportingEvidence
include Swagger::Blocks
swagger_path '/v0/upload_supporting_evidence' do
operation :post do
extend Swagger::Responses::BadRequestError
extend Swagger::Responses::UnprocessableEntityError
key :description, 'Upload a pdf or image file containing supporting evidence for form 526'
key :operationId, 'uploadSupportingEvidence'
key :tags, %w[form_526]
parameter do
key :name, :supporting_evidence_attachment
key :in, :body
key :description, 'Object containing file name'
key :required, true
schema do
key :required, %i[file_data]
property :file_data, type: :string, example: 'filename.pdf'
property :password, type: :string, example: 'My Password'
end
end
response 200 do
key :description, 'Response is ok'
schema do
key :$ref, :UploadSupportingEvidence
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/education_career_counseling_claims.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class EducationCareerCounselingClaims
include Swagger::Blocks
swagger_path '/v0/education_career_counseling_claims' do
operation :post do
extend Swagger::Responses::ValidationError
extend Swagger::Responses::SavedForm
key :description, "Submit a '28-8832' to central mail for career counseling"
key :operationId, 'requestCareerCounseling'
key :tags, %w[central_mail_claim]
parameter :optional_authorization
parameter do
key :name, :form
key :in, :body
key :description, 'Dependency claim form data'
key :required, true
schema do
key :type, :string
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/backend_statuses.rb
|
# frozen_string_literal: true
require 'backend_services'
require 'pagerduty/models/service'
module Swagger
module Requests
class BackendStatuses
include Swagger::Blocks
swagger_path '/v0/backend_statuses' do
operation :get do
key :description, 'Gets the current status of all external services'
key :operationId, 'getBackendStatuses'
key :tags, %w[backend_statuses]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :required, %i[data]
property :data, type: :object do
key :required, [:attributes]
property :attributes, type: :object do
key :required, %i[reported_at statuses]
property :reported_at,
type: :string,
description: "The time from the call to PagerDuty's API",
example: '2019-03-21T16:54:34.000Z'
property :statuses do
key :type, :array
items do
property :service, type: :string, example: 'Appeals'
property :service_id, type: :string, example: 'appeals'
property :status,
type: :string,
enum: PagerDuty::Models::Service::STATUSES,
example: PagerDuty::Models::Service::ACTIVE
property :last_incident_timestamp,
type: %i[string null],
example: '2019-03-21T16:54:34.000Z'
end
end
property :maintenance_windows do
key :type, :array
items do
property :id, type: :integer, example: 1
property :external_service, type: :string, example: 'idme'
property :start_time,
type: :string,
description: 'The start time of the maintenance window',
example: '2024-02-17T09:00:00.000Z'
property :end_time,
type: :string,
description: 'The end time of the maintenance window',
example: '2024-02-17T10:00:00.000Z'
property :description,
type: :string,
description: 'The description of the maintenance window',
example: 'ID.me will be down for maintenance'
end
end
end
end
end
end
response 429 do
key :description, 'Exceeded rate limit'
schema do
key :required, [:errors]
property :errors do
key :type, :array
items do
key :required, %i[title detail code status]
property :title, type: :string, example: 'Exceeded rate limit'
property :detail,
type: :string,
example: "Exceeded PagerDuty's API rate limit"
property :code, type: :string, example: 'PAGERDUTY_429'
property :status, type: :string, example: '429'
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/form212680.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class Form212680
include Swagger::Blocks
FORM_ID = '21-2680'
swagger_path '/v0/form212680' do
operation :post do
extend Swagger::Responses::BadRequestError
extend Swagger::Responses::RecordNotFoundError
extend Swagger::Responses::SavedForm
extend Swagger::Responses::UnprocessableEntityError
extend Swagger::Responses::ValidationError
key :description,
"Create a SavedClaim for #{FORM_ID}" \
'(Examination for Housebound Status or Permanent Need for Regular Aid and Attendance),' \
'to be used later for PDF generation'
key :operationId, 'createForm212680Pdf'
key :tags, %w[benefits_forms]
key :produces, ['application/json']
parameter :optional_authorization
parameter do
key :name, :form
key :in, :body
key :description, "Form #{FORM_ID} submission data"
key :required, true
schema do
VetsJsonSchema::SCHEMAS[FORM_ID]['properties']
end
end
end
end
swagger_path '/v0/form212680/download_pdf/{guid}' do
operation :get do
extend Swagger::Responses::RecordNotFoundError
key :description, "Download the submitted #{FORM_ID} PDF form"
key :operationId, 'downloadForm212680Pdf'
key :tags, %w[benefits_forms]
key :produces, ['application/pdf', 'application/json']
parameter :optional_authorization
parameter do
key :name, 'guid'
key :in, :path
key :description, 'the guid from the form submission response'
key :required, true
key :type, :string
end
response 200 do
key :description, 'PDF file successfully generated and ready for download'
schema do
key :type, :file
end
end
end
end
VetsJsonSchema::SCHEMAS.fetch(FORM_ID)['definitions'].each do |key, value|
swagger_schema(key, value)
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/medical_copays.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class MedicalCopays
include Swagger::Blocks
swagger_path '/v0/medical_copays' do
operation :get do
key :description, 'List of user copays for VA facilities'
key :operationId, 'getMedicalCopays'
key :tags, %w[medical_copays]
parameter :authorization
response 200 do
key :description, 'Successful copays lookup'
schema do
key :required, %i[data status]
property :data, type: :array do
items do
property :id, type: :string, example: '3fa85f64-5717-4562-b3fc-2c963f66afa6'
property :pSSeqNum, type: :integer, example: 0
property :pSTotSeqNum, type: :integer, example: 0
property :pSFacilityNum, type: :string
property :pSFacPhoneNum, type: :string
property :pSTotStatement, type: :integer, example: 0
property :pSStatementVal, type: :string
property :pSStatementDate, type: :string
property :pSStatementDateOutput, type: :string
property :pSProcessDate, type: :string
property :pSProcessDateOutput, type: :string
property :pHPatientLstNme, type: :string
property :pHPatientFstNme, type: :string
property :pHPatientMidNme, type: :string
property :pHAddress1, type: :string
property :pHAddress2, type: :string
property :pHAddress3, type: :string
property :pHCity, type: :string
property :pHState, type: :string
property :pHZipCde, type: :string
property :pHZipCdeOutput, type: :string
property :pHCtryNme, type: :string
property :pHAmtDue, type: :integer, example: 0
property :pHAmtDueOutput, type: :string
property :pHPrevBal, type: :integer, example: 0
property :pHPrevBalOutput, type: :string
property :pHTotCharges, type: :integer, example: 0
property :pHTotChargesOutput, type: :string
property :pHTotCredits, type: :integer, example: 0
property :pHTotCreditsOutput, type: :string
property :pHNewBalance, type: :integer, example: 0
property :pHNewBalanceOutput, type: :string
property :pHSpecialNotes, type: :string
property :pHROParaCdes, type: :string
property :pHNumOfLines, type: :integer, example: 0
property :pHDfnNumber, type: :integer, example: 0
property :pHCernerStatementNumber, type: :integer, example: 0
property :pHCernerPatientId, type: :string
property :pHCernerAccountNumber, type: :string
property :pHIcnNumber, type: :string
property :pHAccountNumber, type: :integer, example: 0
property :pHLargeFontIndcator, type: :integer, example: 0
property :details, type: :array do
items do
property :pDDatePosted, type: :string
property :pDDatePostedOutput, type: :string
property :pDTransDesc, type: :string
property :pDTransDescOutput, type: :string
property :pDTransAmt, type: :integer, example: 0
property :pDTransAmtOutput, type: :string
property :pDRefNo, type: :string
end
end
property :station, type: :object do
property :facilitYNum, type: :string
property :visNNum, type: :string
property :facilitYDesc, type: :string
property :cyclENum, type: :string
property :remiTToFlag, type: :string
property :maiLInsertFlag, type: :string
property :staTAddress1, type: :string
property :staTAddress2, type: :string
property :staTAddress3, type: :string
property :city, type: :string
property :state, type: :string
property :ziPCde, type: :string
property :ziPCdeOutput, type: :string
property :baRCde, type: :string
property :teLNumFlag, type: :string
property :teLNum, type: :string
property :teLNum2, type: :string
property :contacTInfo, type: :string
property :dM2TelNum, type: :string
property :contacTInfo2, type: :string
property :toPTelNum, type: :string
property :lbXFedexAddress1, type: :string
property :lbXFedexAddress2, type: :string
property :lbXFedexAddress3, type: :string
property :lbXFedexCity, type: :string
property :lbXFedexState, type: :string
property :lbXFedexZipCde, type: :string
property :lbXFedexBarCde, type: :string
property :lbXFedexContact, type: :string
property :lbXFedexContactTelNum, type: :string
end
end
end
property :status, type: :integer, example: 200
end
end
end
end
swagger_path '/v0/medical_copays/{id}' do
operation :get do
key :description, 'Fetch individual copay statement by id'
key :operationId, 'getMedicalCopayById'
key :tags, %w[medical_copays]
parameter :authorization
response 200 do
key :description, 'Successful copay lookup by id'
schema do
key :required, %i[data status]
property :data, type: :object do
property :id, type: :string, example: '3fa85f64-5717-4562-b3fc-2c963f66afa6'
property :pSSeqNum, type: :integer, example: 0
property :pSTotSeqNum, type: :integer, example: 0
property :pSFacilityNum, type: :string
property :pSFacPhoneNum, type: :string
property :pSTotStatement, type: :integer, example: 0
property :pSStatementVal, type: :string
property :pSStatementDate, type: :string
property :pSStatementDateOutput, type: :string
property :pSProcessDate, type: :string
property :pSProcessDateOutput, type: :string
property :pHPatientLstNme, type: :string
property :pHPatientFstNme, type: :string
property :pHPatientMidNme, type: :string
property :pHAddress1, type: :string
property :pHAddress2, type: :string
property :pHAddress3, type: :string
property :pHCity, type: :string
property :pHState, type: :string
property :pHZipCde, type: :string
property :pHZipCdeOutput, type: :string
property :pHCtryNme, type: :string
property :pHAmtDue, type: :integer, example: 0
property :pHAmtDueOutput, type: :string
property :pHPrevBal, type: :integer, example: 0
property :pHPrevBalOutput, type: :string
property :pHTotCharges, type: :integer, example: 0
property :pHTotChargesOutput, type: :string
property :pHTotCredits, type: :integer, example: 0
property :pHTotCreditsOutput, type: :string
property :pHNewBalance, type: :integer, example: 0
property :pHNewBalanceOutput, type: :string
property :pHSpecialNotes, type: :string
property :pHROParaCdes, type: :string
property :pHNumOfLines, type: :integer, example: 0
property :pHDfnNumber, type: :integer, example: 0
property :pHCernerStatementNumber, type: :integer, example: 0
property :pHCernerPatientId, type: :string
property :pHCernerAccountNumber, type: :string
property :pHIcnNumber, type: :string
property :pHAccountNumber, type: :integer, example: 0
property :pHLargeFontIndcator, type: :integer, example: 0
property :details, type: :array do
items do
property :pDDatePosted, type: :string
property :pDDatePostedOutput, type: :string
property :pDTransDesc, type: :string
property :pDTransDescOutput, type: :string
property :pDTransAmt, type: :integer, example: 0
property :pDTransAmtOutput, type: :string
property :pDRefNo, type: :string
end
end
property :station, type: :object do
property :facilitYNum, type: :string
property :visNNum, type: :string
property :facilitYDesc, type: :string
property :cyclENum, type: :string
property :remiTToFlag, type: :string
property :maiLInsertFlag, type: :string
property :staTAddress1, type: :string
property :staTAddress2, type: :string
property :staTAddress3, type: :string
property :city, type: :string
property :state, type: :string
property :ziPCde, type: :string
property :ziPCdeOutput, type: :string
property :baRCde, type: :string
property :teLNumFlag, type: :string
property :teLNum, type: :string
property :teLNum2, type: :string
property :contacTInfo, type: :string
property :dM2TelNum, type: :string
property :contacTInfo2, type: :string
property :toPTelNum, type: :string
property :lbXFedexAddress1, type: :string
property :lbXFedexAddress2, type: :string
property :lbXFedexAddress3, type: :string
property :lbXFedexCity, type: :string
property :lbXFedexState, type: :string
property :lbXFedexZipCde, type: :string
property :lbXFedexBarCde, type: :string
property :lbXFedexContact, type: :string
property :lbXFedexContactTelNum, type: :string
end
end
property :status, type: :integer, example: 200
end
end
end
end
swagger_path '/v0/medical_copays/get_pdf_statement_by_id/{statement_id}' do
operation :get do
key :description, 'Endpoint to get PDF statement by medical_copay id'
key :operationId, 'getPDFStatementsById'
key :tags, %w[medical_copays]
parameter :authorization
parameter do
key :name, :id
key :in, :path
key :description, 'The type of letter to be downloaded'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Successful PDF download'
schema do
property :data, type: :string, format: 'binary'
end
end
end
end
swagger_path '/v0/medical_copays/send_statement_notifications' do
operation :post do
key :description, 'Endpoint to trigger notifications from new statements'
key :operationId, 'sendNewStatementsNotifications'
key :tags, %w[medical_copays]
key :produces, ['application/json']
key :consumes, ['application/json']
parameter do
key :name, :statements
key :in, :body
key :description, 'An array of statement data sent as a base64 json file'
key :required, true
schema do
key :type, :array
key :required, [:statements]
items do
key :type, :object
property :veteranIdentifier, type: :string, example: '123456789'
property :identifierType, type: :string, example: 'edipi'
property :facilityNum, type: :string, example: '123'
property :facilityName, type: :string, example: 'VA Medical Center'
property :statementDate, type: :string, example: '01/01/2023'
end
end
end
response 200 do
key :description, 'New statement notifications sent successfully'
schema do
key :type, :object
property :status, type: :integer, example: 200
property :message, type: :string, example: 'Parsing and sending notifications'
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/user.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class User
include Swagger::Blocks
swagger_path '/v0/user' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Get user data'
key :operationId, 'getUser'
key :tags, [
'user'
]
parameter :authorization
response 200 do
key :description, 'get user response'
schema do
key :$ref, :UserData
end
end
response 296 do
key :description, 'Get user data with some external service errors'
schema do
allOf do
schema do
key :$ref, :UserInternalServices
end
schema do
property :data, type: :object do
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
property :account, type: %i[object null]
property :va_profile, type: %i[object null]
property :veteran_status, type: %i[object null]
property :vet360_contact_information, type: %i[object null]
end
end
property :meta, type: :object do
key :required, [:errors]
property :errors do
key :type, :array
items do
property :external_service, type: :string
property :start_time, type: :string
property :end_time, type: %i[string null]
property :description, type: :string
property :status, type: :integer
end
end
end
end
end
end
end
end
end
swagger_schema :UserData, required: %i[data meta] do
allOf do
schema do
key :$ref, :Vet360ContactInformation
end
schema do
key :$ref, :UserInternalServices
end
schema do
property :data, type: :object do
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
property :account, type: :object do
property :account_uuid,
type: %w[string null],
example: 'b2fab2b5-6af0-45e1-a9e2-394347af91ef',
description: 'A UUID correlating all user identifiers. Intended to become the user\'s UUID.'
end
property :va_profile, type: :object do
property :status, type: :string
property :birthdate, type: :string
property :family_name, type: :string
property :gender, type: :string
property :is_cerner_patient, type: :boolean
property :facilities, type: :array do
items do
key :required, %i[facility_id is_cerner]
property :facility_id, type: :string
property :is_cerner, type: :boolean
end
end
property :given_names, type: :array do
items do
key :type, :string
end
end
property :va_patient, type: :boolean
property :mhv_account_state,
type: :string,
enum: %w[OK DEACTIVATED MULTIPLE NONE],
example: 'OK',
description: 'DEACTIVATED: user has at least one MHV id that is not active; ' \
'NONE: user has no active MHV ids; ' \
'MULTIPLE: user has multiple active MHV ids; ' \
'OK: user has one MHV id and its active'
property :user_at_pretransitioned_oh_facility,
type: :boolean,
example: true,
description: 'Indicates whether the user is associated with a facility that is ' \
'pre-transitioned to Oracle Health.'
property :user_facility_ready_for_info_alert,
type: :boolean,
example: false,
description: 'Indicates whether the user\'s facility is ready for the blue ' \
'informational alert about Oracle Health.'
property :user_facility_migrating_to_oh,
type: :boolean,
example: false,
description: 'Indicates whether the user is associated with a facility that is ' \
'migrating to Oracle Health.'
end
property :veteran_status, type: :object do
key :required, [:status]
property :is_veteran, type: :boolean, example: true
property :status, type: :string, enum: %w[OK NOT_AUTHORIZED NOT_FOUND SERVER_ERROR], example: 'OK'
property :served_in_military, type: :boolean, example: true
end
end
end
property :meta, type: :object do
key :required, [:errors]
property :errors, type: :null
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/disability_compensation_form.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class DisabilityCompensationForm
include Swagger::Blocks
swagger_path '/v0/disability_compensation_form/rated_disabilities' do
operation :get do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::BadGatewayError
extend Swagger::Responses::BadRequestError
extend Swagger::Responses::ForbiddenError
key :description, 'Get a list of previously rated disabilities for a veteran'
key :operationId, 'getRatedDisabilities'
key :tags, %w[form_526]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :RatedDisabilities
end
end
end
end
swagger_path '/v0/disability_compensation_form/suggested_conditions{params}' do
operation :get do
extend Swagger::Responses::AuthenticationError
key :description, 'Given part of a condition name (medical or lay), return a list of matching conditions'
key :operationId, 'getSuggestedConditions'
key :tags, %w[form_526]
parameter :authorization
parameter do
key :name, :params
key :description,
'part of a medical term of lay term for a medical condition; for example "?name_part=anxiety"'
key :in, :path
key :type, :string
key :required, true
end
response 200 do
key :description, 'Returns a list of conditions'
schema do
key :$ref, :SuggestedConditions
end
end
end
end
swagger_path '/v0/disability_compensation_form/submit_all_claim' do
operation :post do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::ForbiddenError
extend Swagger::Responses::ValidationError
key :description, 'Submit the disability compensation v2 application for a veteran'
key :operationId, 'postSubmitFormV2'
key :tags, %w[form_526]
parameter :authorization
parameter do
key :name, :form526
key :in, :body
key :description, 'Disability Compensation form data'
key :required, true
schema do
key :$ref, :Form526SubmitV2
end
end
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :SubmitDisabilityForm
end
end
end
end
swagger_path '/v0/disability_compensation_form/submission_status/{job_id}' do
operation :get do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::ForbiddenError
extend Swagger::Responses::RecordNotFoundError
key :description, 'Check the status of a submission job'
key :operationId, 'getSubmissionStatus'
key :tags, %w[form_526]
parameter :authorization
parameter do
key :name, :job_id
key :description, 'the job_id for the submission to check the status of'
key :in, :path
key :type, :string
key :required, true
end
response 200 do
key :description, 'Returns the status of a given submission'
schema do
key :$ref, :JobStatus
end
end
end
end
swagger_path '/v0/disability_compensation_form/rating_info' do
operation :get do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::ForbiddenError
key :description, 'Get the total combined disability rating for a veteran'
key :operationId, 'getRatingInfo'
key :tags, %w[form_526]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :RatingInfo
end
end
end
end
swagger_path '/v0/disability_compensation_form/separation_locations' do
operation :get do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::BadGatewayError
extend Swagger::Responses::ServiceUnavailableError
extend Swagger::Responses::ForbiddenError
key :description, 'Get the separation locations from EVSS'
key :operationId, 'getIntakeSites'
key :tags, %w[form_526]
parameter :authorization
response 200 do
key :description, 'Response is OK'
schema do
key :$ref, :SeparationLocations
end
end
response 403 do
key :description, 'forbidden user'
schema do
key :$ref, :Errors
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/disability_compensation_in_progress_forms.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class DisabilityCompensationInProgressForms
include Swagger::Blocks
tags = { tags: %w[in_progress_forms form_526] }
swagger_path '/v0/disability_compensation_in_progress_forms/{id}' do
operation :delete, **tags do
extend Swagger::Responses::AuthenticationError
key :description, 'Delete form data'
key :operationId, 'deleteInProgressForm'
parameter :authorization
parameter do
key :name, :id
key :in, :path
key :description, 'ID of the form'
key :required, true
key :type, :string
end
response 200 do
key :description, 'delete form response'
schema { key :$ref, :InProgressFormResponse }
end
end
operation :get, **tags do
extend Swagger::Responses::AuthenticationError
key :description, 'Get form data'
key :operationId, 'getInProgressForm'
parameter :authorization
parameter do
key :name, :id
key :in, :path
key :description, 'ID of the form'
key :required, true
key :type, :string
end
response 200 do
key :description, 'get form response'
schema { key :$ref, :InProgressFormShowResponse }
end
end
operation :put, **tags do
extend Swagger::Responses::AuthenticationError
extend Swagger::Responses::InternalServerError
key :description, 'Update form data and metadata'
key :operationId, 'updateInProgressForm'
parameter :authorization
parameter do
key :name, :id
key :in, :path
key :description, 'ID of the form'
key :required, true
key :type, :string
end
parameter do
key :name, :payload
key :in, :body
key :description, 'updated form data and metadata. one of "form_data" or "formData" must be present'
key :required, true
schema example: { formData: { lastName: 'Smith' }, metadata: { ver: 1 } } do
property :formData, type: :object, description: '(alias "form_data")'
property :form_data, type: :object, description: '(alias "formData")'
property :metadata, type: :object
end
end
response 200 do
key :description, 'update form response'
schema { key :$ref, :InProgressFormResponse }
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/efolder.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class Efolder
include Swagger::Blocks
swagger_path '/v0/efolder' do
operation :get do
key :summary, 'Provides a list of document ids and descriptions from eFolder'
key :description,
'Provides a list of document ids and descriptions from eFolder. The documents provided are extracted ' \
'from VBMS and compared against a list of documents for the user that is provided by BGS. A merge ' \
'function between the two lists is performed to determine which documents should be viewable for the ' \
'veteran.'
key :operationId, 'getDocuments'
key :tags, %w[efolder]
response 200 do
key :description, 'Document metadata retrieved successfully'
schema do
items do
property :document_id, type: :string
property :doc_type, type: :string
property :type_description, type: :string
property :received_at, type: :string, format: 'date'
end
end
end
end
end
swagger_path '/v0/efolder/{id}' do
operation :get do
key :summary, 'Allows the veteran to download the document'
key :description,
'Provides a method to download a PDF copy of the document. The ID passed into the query string of the ' \
'URL must match the ID that is attached to the document that is provided by VBMS.'
key :operationId, 'getDocument'
key :tags, %w[efolder]
parameter do
key :name, :id
key :in, :path
key :description, 'Document ID of document'
key :required, true
key :type, :string
end
response 200 do
key :description, 'Document download'
schema do
property :data, type: :string, format: 'binary'
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger
|
code_files/vets-api-private/app/swagger/swagger/requests/hca_attachments.rb
|
# frozen_string_literal: true
module Swagger
module Requests
class HCAAttachments
include Swagger::Blocks
swagger_path '/v0/hca_attachments' do
operation :post do
extend Swagger::Responses::BadRequestError
extend Swagger::Responses::UnprocessableEntityError
key :description, 'Submit a health care application attachment'
key :operationId, 'postHealthCareApplicationAttachment'
key :tags, %w[benefits_forms]
parameter :optional_authorization
parameter do
key :name, :hca_attachment
key :in, :body
key :description, 'HCA attachment data'
key :required, true
schema do
key :required, %i[file_data]
property :file_data, type: :string, example: 'filename.pdf'
property :password, type: :string, example: 'My Password'
end
end
response 200 do
key :description, 'submit hca attachment response'
schema do
property :data, type: :object do
key :required, %i[attributes]
property :id, type: :string
property :type, type: :string
property :attributes, type: :object do
key :required, %i[guid]
property :guid, type: :string
end
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/requests
|
code_files/vets-api-private/app/swagger/swagger/requests/gibct/institutions.rb
|
# frozen_string_literal: true
module Swagger
module Requests
module Gibct
class Institutions
include Swagger::Blocks
swagger_path '/v0/gi/institutions/autocomplete' do
operation :get do
key :description, 'Retrieves institution names begining with a set of letters'
key :operationId, 'gibctInstitutionsAutocomplete'
key :tags, %w[gi_bill_institutions]
parameter name: :term, in: :query,
required: true, type: :string, description: 'start of an institution name'
response 200 do
key :description, 'autocomplete response'
schema do
key :$ref, :GibctInstitutionsAutocomplete
end
end
end
end
swagger_path '/v0/gi/institutions/search' do
operation :get do
key :description, 'Retrieves institutions with a partial match for names, or match of city or facility code'
key :operationId, 'gibctInstitutionsSearch'
key :tags, %w[gi_bill_institutions]
parameter name: :term, in: :query,
required: false, type: :string, description: '(partial) institution name, city, or facility code'
response 200 do
key :description, 'search response'
schema do
key :$ref, :GibctInstitutionsSearch
end
end
end
end
swagger_path '/v0/gi/institutions/{id}' do
operation :get do
key :description, 'Get details about an institution'
key :operationId, 'showInstitution'
key :tags, %w[gi_bill_institutions]
parameter name: :id, in: :path, required: true, type: :integer,
description: 'facility code of the institution'
response 200 do
key :description, 'show response'
schema do
key :$ref, :GibctInstitution
end
end
response 404 do
key :description, 'Operation fails with invalid facility code'
schema do
key :$ref, :Errors
end
end
end
end
end
end
end
end
|
0
|
code_files/vets-api-private/app/swagger/swagger/requests
|
code_files/vets-api-private/app/swagger/swagger/requests/gibct/calculator_constants.rb
|
# frozen_string_literal: true
module Swagger
module Requests
module Gibct
class CalculatorConstants
include Swagger::Blocks
swagger_path '/v0/gi/calculator_constants' do
operation :get do
key :description, 'Gets all calculator constants'
key :operationId, 'gibctCalculatorConstantsIndex'
key :tags, %w[gi_bill_institutions]
response 200 do
key :description, 'autocomplete response'
schema do
key :$ref, :GibctCalculatorConstants
end
end
end
end
end
end
end
end
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.