:doc:`IoT <../../iot>` / Client / get_package_version

*******************
get_package_version
*******************



.. py:method:: IoT.Client.get_package_version(**kwargs)

  

  Gets information about the specified package version.

   

  Requires permission to access the `GetPackageVersion <https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsiot.html#awsiot-actions-as-permissions>`__ action.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/iot-2015-05-28/GetPackageVersion>`_  


  **Request Syntax**
  ::

    response = client.get_package_version(
        packageName='string',
        versionName='string'
    )
    
  :type packageName: string
  :param packageName: **[REQUIRED]** 

    The name of the associated package.

    

  
  :type versionName: string
  :param versionName: **[REQUIRED]** 

    The name of the target package version.

    

  
  
  :rtype: dict
  :returns: 
    
    **Response Syntax**

    
    ::

      {
          'packageVersionArn': 'string',
          'packageName': 'string',
          'versionName': 'string',
          'description': 'string',
          'attributes': {
              'string': 'string'
          },
          'artifact': {
              's3Location': {
                  'bucket': 'string',
                  'key': 'string',
                  'version': 'string'
              }
          },
          'status': 'DRAFT'|'PUBLISHED'|'DEPRECATED',
          'errorReason': 'string',
          'creationDate': datetime(2015, 1, 1),
          'lastModifiedDate': datetime(2015, 1, 1),
          'sbom': {
              's3Location': {
                  'bucket': 'string',
                  'key': 'string',
                  'version': 'string'
              }
          },
          'sbomValidationStatus': 'IN_PROGRESS'|'FAILED'|'SUCCEEDED',
          'recipe': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **packageVersionArn** *(string) --* 

        The ARN for the package version.

        
      

      - **packageName** *(string) --* 

        The name of the software package.

        
      

      - **versionName** *(string) --* 

        The name of the package version.

        
      

      - **description** *(string) --* 

        The package version description.

        
      

      - **attributes** *(dict) --* 

        Metadata that were added to the package version that can be used to define a package version’s configuration.

        
        

        - *(string) --* 
          

          - *(string) --* 
    
  
      

      - **artifact** *(dict) --* 

        The various components that make up a software package version.

        
        

        - **s3Location** *(dict) --* 

          The S3 location.

          
          

          - **bucket** *(string) --* 

            The S3 bucket.

            
          

          - **key** *(string) --* 

            The S3 key.

            
          

          - **version** *(string) --* 

            The S3 bucket version.

            
      
    
      

      - **status** *(string) --* 

        The status associated to the package version. For more information, see `Package version lifecycle <https://docs.aws.amazon.com/iot/latest/developerguide/preparing-to-use-software-package-catalog.html#package-version-lifecycle>`__.

        
      

      - **errorReason** *(string) --* 

        Error reason for a package version failure during creation or update.

        
      

      - **creationDate** *(datetime) --* 

        The date when the package version was created.

        
      

      - **lastModifiedDate** *(datetime) --* 

        The date when the package version was last updated.

        
      

      - **sbom** *(dict) --* 

        The software bill of materials for a software package version.

        
        

        - **s3Location** *(dict) --* 

          The S3 location.

          
          

          - **bucket** *(string) --* 

            The S3 bucket.

            
          

          - **key** *(string) --* 

            The S3 key.

            
          

          - **version** *(string) --* 

            The S3 bucket version.

            
      
    
      

      - **sbomValidationStatus** *(string) --* 

        The status of the validation for a new software bill of materials added to a software package version.

        
      

      - **recipe** *(string) --* 

        The inline job document associated with a software package version used for a quick job deployment.

        
  
  **Exceptions**
  
  *   :py:class:`IoT.Client.exceptions.ThrottlingException`

  
  *   :py:class:`IoT.Client.exceptions.InternalServerException`

  
  *   :py:class:`IoT.Client.exceptions.ValidationException`

  
  *   :py:class:`IoT.Client.exceptions.ResourceNotFoundException`

  