Skip to content

Releases: janivihervas/contentful-go

2.1.0

17 Sep 11:35
Compare
Choose a tag to compare

2.0.1

20 Aug 16:50
d23c1c9
Compare
Choose a tag to compare

Fix examples

2.0.0

02 Mar 06:43
59f9750
Compare
Choose a tag to compare

BREAKING CHANGES

Rename json field values of contentful.Information:

type Information struct {
-	ID          string    `json:"contentful_id"`
+	ID          string    `json:"contentfulId"`
-	ContentType string    `json:"contentful_contentType"`
+	ContentType string    `json:"contentfulContentType"`
-	Revision    int       `json:"contentful_revision"`
+	Revision    int       `json:"contentfulRevision"`
-	CreatedAt   time.Time `json:"contentful_createdAt"`
+	CreatedAt   time.Time `json:"contentfulCreatedAt"`
-	UpdatedAt   time.Time `json:"contentful_updatedAt"`
+	UpdatedAt   time.Time `json:"contentfulUpdatedAt"`
-	Locale      string    `json:"contentful_locale"`
+	Locale      string    `json:"contentfulLocale"`
}

You're affected by this change only if you are using your own struct type for the metadata or you're using the JSON form of the information struct.

MIGRATION GUIDE

Rename your usages based on the above diff and you're good to go.

1.0.0

25 Feb 16:13
124d5ae
Compare
Choose a tag to compare

Features:

  • Automatically inject Contentful references to Go structs i.e. flatten the result JSON
  • Can use either the Preview API or the Content Delivery API
  • Methods for fetching many entries or one entry
  • Convenience types for Contentful's assets, files and entry information
  • Convenience methods for query parameters