.. raw:: html Container Tag History ===================== .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted The tag history stores a list of image that still have or used to have the given tag .. tab-set:: .. tab-item:: Fields .. div:: :name: ``registry`` ``registry`` | String :bdg-danger:`required` .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted Hostname of the registry where the repository can be accessed. .. div:: :name: ``repository`` ``repository`` | String :bdg-danger:`required` .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted Repository name. .. div:: :name: ``tag`` ``tag`` | String :bdg-danger:`required` .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted The image tag name. .. div:: :name: ``tag_type`` ``tag_type`` | String :bdg-danger:`required` .. dropdown:: String parameters :animate: fade-in ``enum`` persistent | floating .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted The tag type i.e. for floating or persistent. .. div:: :name: ``object_type`` ``object_type`` | String .. dropdown:: String parameters :animate: fade-in ``constant`` | containerTagHistory .. div:: :name: ``history`` ``history`` | List[:doc:`/objects/History`] .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted Array with the tag history information. .. div:: :name: ``_id`` ``_id`` | :doc:`/scalars/ObjectID` :bdg-primary-line:`read-only` .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted MongoDB unique _id .. div:: :name: ``creation_date`` ``creation_date`` | :doc:`/scalars/DateTime` :bdg-primary-line:`read-only` .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted The date when the entry was created. Value is created automatically on creation. .. div:: :name: ``last_update_date`` ``last_update_date`` | :doc:`/scalars/DateTime` :bdg-primary-line:`read-only` .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted The date when the entry was last updated. .. tab-item:: Links .. div:: :name: ``images`` ``images`` | :doc:`/endpoints/RESTGetImagesForTagHistory` .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted URI to this tag's images. .. tab-item:: Indexes .. div:: :name: ``containerTagHistory_identity`` ``containerTagHistory_identity`` .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted Fields - ``repository: ASC`` - ``registry: ASC`` - ``tag: ASC`` .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted Parameters - ``unique: True`` - ``sparse: True`` .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted Description | Index for the containerTagHistory collection based on the repository, registry and tag fields | .. tab-item:: Edges .. div:: :name: ``edges.images`` ``edges.images`` | List[:doc:`ContainerImage`] .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted Edge to related container images. .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted Parent arguments: ['_id'] .. div:: sd-font-weight-light sd-fs-6 sd-font-italic sd-text-muted Uses GQL query: find_tag_history_images .. dropdown:: Example queries :animate: fade-in .. raw:: html
                {
                    find_tag_histories(page: 0, page_size: 50, sort_by: [{ field: "creation_date", order: DESC }]) {
                        error {
                            detail
                            status
                        }
                        total # omit for better performance
                        page_size
                        page
                        data {
                            _id
                            edges {
                                images {
                                    error {
                                        status
                                        detail
                                    }
                                    data {
                                        _id
                                    }
                                }
                            }
                        }
                    }
                }
                
                {
                    get_tag_history(id: "6304c560cbb2b2d2d4053b8e") {
                        error {
                            detail
                            status
                        }
                        data {
                            _id
                            edges {
                                images {
                                    error {
                                        status
                                        detail
                                    }
                                    data {
                                        _id
                                    }
                                }
                            }
                        }
                    }
                }
                
                {
                    get_tag_history_by_tag_name(registry: "example", repository: "example", tag: "example") {
                        error {
                            detail
                            status
                        }
                        data {
                            _id
                            edges {
                                images {
                                    error {
                                        status
                                        detail
                                    }
                                    data {
                                        _id
                                    }
                                }
                            }
                        }
                    }
                }
                
.. tab-item:: Usage .. dropdown:: Endpoints :animate: fade-in - :doc:`GET - /tag-history ` - :doc:`GET - /tag-history/id/{identifier} ` - :doc:`GET - /tag-history/registry/{registry}/repository/{repository}/tag/{tag} ` .. dropdown:: Queries and Mutations :animate: fade-in - :doc:`find_tag_histories ` - :doc:`get_tag_history ` - :doc:`get_tag_history_by_tag_name `