@@ -467,6 +467,45 @@ def search_cases(parent, page_size: nil, page_token: nil, query: nil, fields: ni
467467 execute_or_queue_command ( command , &block )
468468 end
469469
470+ # Retrieve an attachment associated with a support case. EXAMPLES: cURL: ```
471+ # shell attachment="projects/some-project/cases/23598314/attachments/
472+ # 0684M00000P3h1fQAB" curl \ --header "Authorization: Bearer $(gcloud auth print-
473+ # access-token)" \ "https://cloudsupport.googleapis.com/v2/$attachment" ```
474+ # Python: ```python import googleapiclient.discovery api_version = "v2"
475+ # supportApiService = googleapiclient.discovery.build( serviceName="cloudsupport"
476+ # , version=api_version, discoveryServiceUrl=f"https://cloudsupport.googleapis.
477+ # com/$discovery/rest?version=`api_version`", ) request = ( supportApiService.
478+ # cases() .attachments() .get(name="projects/some-project/cases/43595344/
479+ # attachments/0684M00000P3h1fQAB") ) print(request.execute()) ```
480+ # @param [String] name
481+ # Required. The name of the attachment to get.
482+ # @param [String] fields
483+ # Selector specifying which fields to include in a partial response.
484+ # @param [String] quota_user
485+ # Available to use for quota purposes for server-side applications. Can be any
486+ # arbitrary string assigned to a user, but should not exceed 40 characters.
487+ # @param [Google::Apis::RequestOptions] options
488+ # Request-specific options
489+ #
490+ # @yield [result, err] Result & error if block supplied
491+ # @yieldparam result [Google::Apis::CloudsupportV2::Attachment] parsed result object
492+ # @yieldparam err [StandardError] error object if request failed
493+ #
494+ # @return [Google::Apis::CloudsupportV2::Attachment]
495+ #
496+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
497+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
498+ # @raise [Google::Apis::AuthorizationError] Authorization is required
499+ def get_case_attachment ( name , fields : nil , quota_user : nil , options : nil , &block )
500+ command = make_simple_command ( :get , 'v2/{+name}' , options )
501+ command . response_representation = Google ::Apis ::CloudsupportV2 ::Attachment ::Representation
502+ command . response_class = Google ::Apis ::CloudsupportV2 ::Attachment
503+ command . params [ 'name' ] = name unless name . nil?
504+ command . query [ 'fields' ] = fields unless fields . nil?
505+ command . query [ 'quotaUser' ] = quota_user unless quota_user . nil?
506+ execute_or_queue_command ( command , &block )
507+ end
508+
470509 # List all the attachments associated with a support case. EXAMPLES: cURL: ```
471510 # shell case="projects/some-project/cases/23598314" curl \ --header "
472511 # Authorization: Bearer $(gcloud auth print-access-token)" \ "https://
@@ -561,6 +600,44 @@ def create_case_comment(parent, comment_object = nil, fields: nil, quota_user: n
561600 execute_or_queue_command ( command , &block )
562601 end
563602
603+ # Retrieve a comment. EXAMPLES: cURL: ```shell comment="projects/some-project/
604+ # cases/43595344/comments/234567890" curl \ --header "Authorization: Bearer $(
605+ # gcloud auth print-access-token)" \ "https://cloudsupport.googleapis.com/v2/$
606+ # comment" ``` Python: ```python import googleapiclient.discovery api_version = "
607+ # v2" supportApiService = googleapiclient.discovery.build( serviceName="
608+ # cloudsupport", version=api_version, discoveryServiceUrl=f"https://cloudsupport.
609+ # googleapis.com/$discovery/rest?version=`api_version`", ) request =
610+ # supportApiService.cases().comments().get( name="projects/some-project/cases/
611+ # 43595344/comments/234567890", ) print(request.execute()) ```
612+ # @param [String] name
613+ # Required. The name of the comment to retrieve.
614+ # @param [String] fields
615+ # Selector specifying which fields to include in a partial response.
616+ # @param [String] quota_user
617+ # Available to use for quota purposes for server-side applications. Can be any
618+ # arbitrary string assigned to a user, but should not exceed 40 characters.
619+ # @param [Google::Apis::RequestOptions] options
620+ # Request-specific options
621+ #
622+ # @yield [result, err] Result & error if block supplied
623+ # @yieldparam result [Google::Apis::CloudsupportV2::Comment] parsed result object
624+ # @yieldparam err [StandardError] error object if request failed
625+ #
626+ # @return [Google::Apis::CloudsupportV2::Comment]
627+ #
628+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
629+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
630+ # @raise [Google::Apis::AuthorizationError] Authorization is required
631+ def get_case_comment ( name , fields : nil , quota_user : nil , options : nil , &block )
632+ command = make_simple_command ( :get , 'v2/{+name}' , options )
633+ command . response_representation = Google ::Apis ::CloudsupportV2 ::Comment ::Representation
634+ command . response_class = Google ::Apis ::CloudsupportV2 ::Comment
635+ command . params [ 'name' ] = name unless name . nil?
636+ command . query [ 'fields' ] = fields unless fields . nil?
637+ command . query [ 'quotaUser' ] = quota_user unless quota_user . nil?
638+ execute_or_queue_command ( command , &block )
639+ end
640+
564641 # List all the comments associated with a case. EXAMPLES: cURL: ```shell case="
565642 # projects/some-project/cases/43595344" curl \ --header "Authorization: Bearer $(
566643 # gcloud auth print-access-token)" \ "https://cloudsupport.googleapis.com/v2/$
@@ -660,7 +737,7 @@ def download_medium(name, fields: nil, quota_user: nil, download_dest: nil, opti
660737 # is in a file I'm uploading using CSAPI." \ > "./example_file.txt" case="
661738 # projects/some-project/cases/43594844" curl \ --header "Authorization: Bearer $(
662739 # gcloud auth print-access-token)" \ --data-binary @"./example_file.txt" \ "
663- # https://cloudsupport.googleapis.com/upload/v2beta /$case/attachments?attachment.
740+ # https://cloudsupport.googleapis.com/upload/v2 /$case/attachments?attachment.
664741 # filename=uploaded_via_curl.txt" ``` Python: ```python import googleapiclient.
665742 # discovery api_version = "v2" supportApiService = googleapiclient.discovery.
666743 # build( serviceName="cloudsupport", version=api_version, discoveryServiceUrl=f"
0 commit comments