Method: purchases.products.consume
    
    
      
    
    
      
      Mit Sammlungen den Überblick behalten
    
    
      
      Sie können Inhalte basierend auf Ihren Einstellungen speichern und kategorisieren.
    
  
    
  
      
    
  
  
  
  
  
  
    
    
    
    
    
    
      
      
      
        Es wird ein Kauf für einen In-App-Artikel konsumiert.
      
      
        
          HTTP-Anfrage
          POST https://androidpublisher.googleapis.com/androidpublisher/v3/applications/{packageName}/purchases/products/{productId}/tokens/{token}:consume
Die URL verwendet die Syntax der gRPC-Transcodierung.
        
        
          Pfadparameter
          
            
              
              
            
            
              
                | Parameter | 
              
            
            
              
                packageName | 
                
                   string 
                  Der Paketname der Anwendung, in der das In-App-Produkt verkauft wurde (z. B. „com.beispiel.app“). 
                 | 
              
              
                productId | 
                
                   string 
                  Die SKU des In-App-Produkts (z. B. „com.some.thing.inapp1“). 
                 | 
              
              
                token | 
                
                   string 
                  Das Token, das dem Gerät des Nutzers beim Kauf des In-App-Produkts bereitgestellt wurde. 
                 | 
              
            
          
        
        
          Anfragetext
          Der Anfragetext muss leer sein.
        
        
          Antworttext
          Wenn der Vorgang erfolgreich ist, ist der Antworttext leer.
        
        
          Beispiel
          Hier ein Beispiel für eine Anfrage:
          curl \
  -X POST \
  'https://androidpublisher.googleapis.com/androidpublisher/v3/applications/com.example.app/purchases/products/exampleSKU/tokens/exampleToken:consume' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer [YOUR_ACCESS_TOKEN]'
        
        
          Autorisierungsbereiche
          Erfordert den folgenden OAuth-Bereich:
          
            https://www.googleapis.com/auth/androidpublisher 
          
        
      
      
    
  
  
  
  
 
  
    
      
      
    
    
      
    
    
  
       
    
    
      
    
  
  
  Sofern nicht anders angegeben, sind die Inhalte dieser Seite unter der Creative Commons Attribution 4.0 License und Codebeispiele unter der Apache 2.0 License lizenziert. Weitere Informationen finden Sie in den Websiterichtlinien von Google Developers. Java ist eine eingetragene Marke von Oracle und/oder seinen Partnern.
  Zuletzt aktualisiert: 2025-07-26 (UTC).
  
  
  
    
      [[["Leicht verständlich","easyToUnderstand","thumb-up"],["Mein Problem wurde gelöst","solvedMyProblem","thumb-up"],["Sonstiges","otherUp","thumb-up"]],[["Benötigte Informationen nicht gefunden","missingTheInformationINeed","thumb-down"],["Zu umständlich/zu viele Schritte","tooComplicatedTooManySteps","thumb-down"],["Nicht mehr aktuell","outOfDate","thumb-down"],["Problem mit der Übersetzung","translationIssue","thumb-down"],["Problem mit Beispielen/Code","samplesCodeIssue","thumb-down"],["Sonstiges","otherDown","thumb-down"]],["Zuletzt aktualisiert: 2025-07-26 (UTC)."],[],["The core function is consuming a purchase for an in-app item via a `POST` HTTP request. The request targets a specific URL using gRPC Transcoding syntax. It requires three path parameters: `packageName`, `productId`, and `token`. The request body must be empty. A successful operation returns an empty response body. Authorization requires the `https://www.googleapis.com/auth/androidpublisher` OAuth scope. Key actions are providing the necessary path parameters for the given request and ensuring an empty request body.\n"]]