View all results on Prisma Cloud Compute API

View all results on Prisma Cloud Compute API

475
Created On 05/15/24 07:35 AM - Last Modified 07/02/25 13:54 PM


Objective


  • View all results while invoking Prisma Cloud Compute (PCC) API calls.


Environment


Prisma Cloud Compute API

Procedure


  • By default paginated responses for PCC API are limited to 50 returned objects to avoid DoS the console.
    • This limit cannot be increased.
  • To be able to view additional objects the use of the offset option is necessary.
    • The offset option sets the position in the dataset to a particular record.
  • For example, in a default API call the following URL is used:
    • curl -k -H 'Authorization: Bearer <token>' https://<compute URL>:<port>/api/v32.04/images
    • This is equivalent to the following API call:
      • curl -k -H 'Authorization: Bearer <token>' https://<compute URL>:<port>/api/v32.04/images?limit=50&offset=0
      • The "offset=0" indicates the response objects will start at index position 0, while the "limit=50" indicates that the response will return 50 objects.
      • Images with index value 0-49 will be seen (or 50 total objects).
    • In order to see the next 50 objects, the offset must be set to a value which is equivalent to the number of objects returned.
      • For example, to view objects 50-99, the API call would look as follows:
      • curl -k -H 'Authorization: Bearer <token>' https://<compute URL>:<port>/api/v32.04/images?limit=50&offset=50


Additional Information


  • Note, only the offset will be incremented. The number of objects returned will still be 50 total objects.


Actions
  • Print
  • Copy Link

    https://knowledgebase.paloaltonetworks.com/KCSArticleDetail?id=kA14u000000HDAPCA4&lang=en_US&refURL=http%3A%2F%2Fknowledgebase.paloaltonetworks.com%2FKCSArticleDetail