postman-open-technologies / collection-format-mindmap

An Interractive mind map for Postman Collection Format
Apache License 2.0
3 stars 1 forks source link

Get familiar with the structure of a collection #2

Open Gbahdeyboh opened 1 year ago

Gbahdeyboh commented 1 year ago

The collection format is really powerful; it forms the basis of collections in Postman. Today, hundreds of thousands of collections are publicly available.

We have a documentation available for the collection format. It is an excellent place to get started with understanding the structure of a collection. Peruse this documentation and get acquainted with the collection format.

When you are done, answer the following questions as a comment under this issue.

1) In your own words, what unique value do you think the collection format provides? 2) How is the collection format related to collections in Postman and how do they complement each other?

yashm277 commented 1 year ago

In Postman, a collection is a group of requests, scripts, tests, and other related elements that can be organized and saved together for easy access and sharing. The Collection format in Postman is a JSON-based format that is used to store and share collections of API requests and related information.

The Collection format in Postman provides a unique value to developers by allowing them to easily manage and share collections of API requests and related information. The format provides a standardized way to store and organize requests, scripts, tests, and other elements, making it easier to collaborate on API development projects.

The Collection format in Postman is closely related to Collections in Postman, as it defines the structure and properties of the Collection. The Collection format defines the properties and structure of each request, including the URL, HTTP method, headers, body, and other relevant information. It also defines other elements of the Collection, such as scripts, tests, and metadata.

The Collection format and Collections in Postman complement each other by providing a way to manage and organize API requests and related information. Collections in Postman are used to group related requests and other elements together, while the Collection format defines the structure and properties of each request and element.

The Collection format also enables developers to easily export and share Collections with other team members or developers. This allows developers to collaborate on API development projects more easily, as everyone can work from the same Collection format and avoid the need for manual organization and sharing of API requests.

Overall, the Collection format provides a unique value to developers by standardizing the way API requests and related information are stored and shared. By working together with Collections in Postman, the Collection format helps developers to streamline their API development workflows and collaborate more effectively on projects.

yashm277 commented 1 year ago

@Gbahdeyboh would be grateful if you could give feedback on the above finished task.

Huzaifa785 commented 1 year ago

So in order to get familiar with this, I watched the live stream that you (@Gbahdeyboh ) did 5 days ago on Postman's YouTube channel and I have dropped some of the important points here:

Basic Definitions

More on Collections

  1. Collections are client-side.
  2. Once you have added all API requests and the necessary information, you can share the collection with anyone and they can come to your postman and test APIs, etc.
  3. You can convert the collection format (exported JSON) into an OpenApi definition or vice versa.
  4. You can generate code snippets from the exported JSON.

Structure of Collection Format

Collection Format Structure

Here, you can think of each node as an object. I read the documentation here 🚀

Answers to the questions

  1. In your own words, what unique value do you think the collection format provides?

    • According to me, I guess with the help of the collection format, we can modify the collection more precisely according to our needs, if I am right and I think this is one of the unique features. Also, with the help of the collection format, we can turn it into an OpenApi definition and this will be also very useful.
  2. How is the collection format related to collections in Postman and how do they complement each other?

    • In Postman, a "collection" is a group of related API requests that can be saved and shared with others. Collections in Postman are represented as JSON files that contain information about each request in the collection, such as the endpoint URL, HTTP method, headers, parameters, and more.

A collection format is simply the JSON that you exported of your collection.

Actually, the collections and collection format complement very well as we can export the collection that generates the collections format making it possible for us to precisely modify some changes if there, also we can change generate code snippets, convert it OpenApi definition and vice versa, etc.

jaydip1235 commented 1 year ago

Hi @Gbahdeyboh

1.

In my opinion, the collection format provides a unique value by allowing us to organize and store data in a structured and efficient way

2. Collections and collection formats complement each other in several ways:

Thank you, Jaydip Dey

KaalaAadmi commented 1 year ago

Hi @Gbahdeyboh

In your own words, what unique value do you think the collection format provides?

In my opinion, a collection format helps in managing and manipulating data more efficiently. It also helps users group similar requests together in a folder inside the collection, thus, helping them segregate the requests for a project by combining similar ones in a folder. When the collections are exported, Postman saves the collections as JSON, so, it allows for easy conversion to other standard formats. This helps in sharing and collaborating with others. Users can also store necessary comments describing their requests and the headers and parameters, which helps in explaining the requests. We can also add a description of the collection itself. Users can apply many methods like filtering, sorting and mapping. The concept of a runner also helps in testing all the requests in a collection by writing necessary pre-run and post-run scripts. This way, the testing is effortless and seamless. Even if a collection is shared with someone who does not have an account with postman, they can easily import the collection into their choice of API testing tool and use it. Overall, postman's collection format simplifies the process of managing and working with a large amount of data(requests, making it a valuable tool for developers and API professionals.

How is the collection format related to collections in Postman and how do they complement each other?

As the collection format in Postman is a way of storing and organising sets of API requests along with their metadata for the requests, their headers and query parameters into a single JSON document, it enables users to manipulate and manage vast amounts of data efficiently also allowing for easier collaboration with others. Collections allow users to organize their API requests in a more logical and structured way by allowing folders and nested folders, making it easier to manage and work with larger sets of requests.

Collections can also be used to store pre-run and post-run scripts which would be applied to all the API requests in the collection. Postman collections come in handy while making use of the runner which helps in making testing the API requests easy. Collections contain multiple requests, each with its own set of parameters, headers and body data along with the API request-specific pre-run and post-run script.

The collection format and collections in Postman complement each other by providing a more comprehensive way to manage and work with APIs. The collection format provides a way to structure and organize all the related information about an API in a single document, while collections provide a way to group related requests together for easier management and execution. Together, they provide a powerful tool for developers and other professionals who work with APIs.

@Gbahdeyboh please let me know whether my understanding is correct, or if they can be improved in any way.

Thanks, Arnav Bhattacharya