1
0
mirror of https://github.com/dstotijn/go-notion.git synced 2025-06-08 23:46:12 +02:00

17 Commits

Author SHA1 Message Date
Lucas
a0926892c2
Add support for Page's Icon retrieval and updates (#21)
* Add support for Page's Icon retrieval and updates

* Add support for creating a page with an icon

* Fix tests, add icon validation

* Remove unknown icon type `file`

* Add icon support for "create database" endpoint

Co-authored-by: David Stotijn <dstotijn@gmail.com>
2021-12-09 17:57:08 +01:00
David Stotijn
5e7e8ed54c Add "create database" endpoint 2021-07-20 22:50:53 +02:00
David Stotijn
597978fa0d Add Parent field to Database type
Ref: https://developers.notion.com/changelog/database-objects-now-return-parent
2021-07-20 20:48:35 +02:00
Alexandre Falardeau
969ba033ff
Enable empty DatabaseQueryFilter (#15)
* Add test for "DatabaseQuery"

* Fix DatabaseQuery Filter field type

* Assert database query JSON omit logic in `Client` tests

Co-authored-by: Alexandre Falardeau <asfal@AsFal-Laptop.local>
Co-authored-by: David Stotijn <dstotijn@gmail.com>
2021-05-25 18:24:52 +02:00
David Stotijn
c675641a4c Fix database page property types
Fixes #12
2021-05-24 18:00:20 +02:00
David Stotijn
1d8c71b79b Add missing database property types 2021-05-24 16:57:28 +02:00
David Stotijn
e5130d1fde Fix incorrect types for Formula, Relation and Rollup page props
Fixes #11
2021-05-24 16:33:03 +02:00
David Stotijn
c16fdfbc88 Use struct pointers for various DatabaseQueryFilter fields
Fixes: #2
2021-05-17 22:00:05 +02:00
David Stotijn
0e0f6c77aa Add tests for NewClient and Client.FindDatabaseByID 2021-05-17 21:08:13 +02:00
David Stotijn
e32f7422cd Add "update page properties" endpoint support 2021-05-15 18:06:11 +02:00
David Stotijn
b2af8b7d0b Add "create a page" endpoint 2021-05-15 13:42:01 +02:00
David Stotijn
4726db0bf2 Add context.Context arg for Client methods, move methods to client.go 2021-05-15 00:02:08 +02:00
David Stotijn
0c1e15e0a7 Add "query database" endpoint 2021-05-14 23:48:30 +02:00
David Stotijn
0c31224d6f Remove database property metadata types that are empty 2021-05-14 18:49:00 +02:00
David Stotijn
fccdde0f5b Simplify APIError.Unwrap, fix missing error message prefixes 2021-05-14 18:24:56 +02:00
David Stotijn
d9867284b5 Use DatabaseProperty in DB props map 2021-05-14 17:34:46 +02:00
David Stotijn
e9e9dca708 Initial commit 2021-05-13 22:11:32 +02:00