multiwoven-integrations 0.8.1 → 0.8.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0ffac7c24440182d18b579311e5f74ab0d5fe796cc93bbc67f7db1ef31bf0eaf
4
- data.tar.gz: 207dd699430c35d4878e06ffe337ae8a494d25ca426801ae1d0b92ed474c1393
3
+ metadata.gz: 5328da16858cd290955a6b993a1ee19285490298eeab3573b8ad55b3dacf7258
4
+ data.tar.gz: ef061954be00b3a90b5927f33e2633b05267968036123e743d5e3438ab4b18fd
5
5
  SHA512:
6
- metadata.gz: 3fedbdb2d191a73eb90a5b717c81488eb5849daa318d975ddd974a592189e3b0e1df5a812ed4ef50436758d53fe3e7190aca9b7f1af69028a32c20922584b121
7
- data.tar.gz: 40872fb3db0c280f194d122aed885db7b4dc19cef6511f510eccbf910957b7db00e12de58a645ed345b91e257ff4d7c369d9607b9e5cf3a5f8ed2d5ea5816ab1
6
+ metadata.gz: 5a74373e13a6a7f25385e675f8bad255383bfb937f60cb5f78b11512f4bcce749fa15da8f3c63530feeb0edfb5594a6270e857bc0d8975396de09a69f2ee9463
7
+ data.tar.gz: a3262d0ab25b5c7bc3d69f2499068c7fee1a7116c3fe07b23db26177b00e2572e3b721383ed70d2ab9118bf3c144af1b89cb6ce2b2c37f9081a0a18df12e7db5
@@ -40,7 +40,7 @@ module Multiwoven
40
40
  MS_EXCEL_TABLE_ROW_WRITE_API = "https://graph.microsoft.com/v1.0/drives/%<drive_id>s/items/%<item_id>s/"\
41
41
  "workbook/worksheets/%<sheet_name>s/tables/%<table_name>s/rows"
42
42
  MS_EXCEL_TABLE_API = "https://graph.microsoft.com/v1.0/drives/%<drive_id>s/items/%<item_id>s/workbook/"\
43
- "worksheets/sheet/tables?$select=name"
43
+ "worksheets/%<sheet_name>s/tables?$select=name"
44
44
  MS_EXCEL_FILES_API = "https://graph.microsoft.com/v1.0/drives/%<drive_id>s/root/children"
45
45
  MS_EXCEL_WORKSHEETS_API = "https://graph.microsoft.com/v1.0/drives/%<drive_id>s/items/%<item_id>s/"\
46
46
  "workbook/worksheets"
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "data": {
3
3
  "name": "Airtable",
4
- "title": "airtable",
4
+ "title": "Airtable",
5
5
  "connector_type": "destination",
6
6
  "category": "Productivity Tools",
7
7
  "documentation_url": "https://docs.multiwoven.com/destinations/productivity-tools/airtable",
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "data": {
3
3
  "name": "DatabricksLakehouse",
4
- "title": "Databricks Datawarehouse",
4
+ "title": "Databricks Data Warehouse",
5
5
  "connector_type": "destination",
6
6
  "category": "Database",
7
7
  "documentation_url": "https://docs.multiwoven.com/destinations/databricks_lakehouse",
@@ -3,7 +3,7 @@
3
3
  "name": "FacebookCustomAudience",
4
4
  "title": "Facebook Custom Audiences",
5
5
  "connector_type": "destination",
6
- "category": "Adtech",
6
+ "category": "Ad-Tech",
7
7
  "documentation_url": "https://docs.mutliwoven.com",
8
8
  "github_issue_label": "destination-facebook",
9
9
  "icon": "icon.svg",
@@ -3,7 +3,7 @@
3
3
  "name": "Http",
4
4
  "title": "HTTP",
5
5
  "connector_type": "destination",
6
- "category": "Http",
6
+ "category": "HTTP",
7
7
  "documentation_url": "https://docs.multiwoven.com/destinations/http",
8
8
  "github_issue_label": "destination-http",
9
9
  "icon": "icon.svg",
@@ -49,8 +49,7 @@ module Multiwoven::Integrations::Destination
49
49
  excel_files = get_file(token, drive_id)
50
50
  worksheet = excel_files.find { |file| file[:name] == file_name }
51
51
  item_id = worksheet[:id]
52
-
53
- table = get_table(token, drive_id, item_id)
52
+ table = get_table(token, drive_id, item_id, sheet_name)
54
53
  write_url = format(MS_EXCEL_TABLE_ROW_WRITE_API, drive_id: drive_id, item_id: item_id, sheet_name: sheet_name,
55
54
  table_name: table["name"])
56
55
  payload = { values: records.map(&:values) }
@@ -69,8 +68,8 @@ module Multiwoven::Integrations::Destination
69
68
  JSON.parse(response.body)["id"]
70
69
  end
71
70
 
72
- def get_table(token, drive_id, item_id)
73
- table_url = format(MS_EXCEL_TABLE_API, drive_id: drive_id, item_id: item_id)
71
+ def get_table(token, drive_id, item_id, sheet_name)
72
+ table_url = format(MS_EXCEL_TABLE_API, drive_id: drive_id, item_id: item_id, sheet_name: sheet_name)
74
73
  response = Multiwoven::Integrations::Core::HttpClient.request(
75
74
  table_url,
76
75
  HTTP_GET,
@@ -114,9 +113,14 @@ module Multiwoven::Integrations::Destination
114
113
  headers: auth_headers(token)
115
114
  )
116
115
  sheets_data = JSON.parse(sheet_response.body)
116
+ column_names = if sheets_data.key?("error")
117
+ ["Column A"]
118
+ else
119
+ sheets_data["values"].first
120
+ end
117
121
  result << {
118
122
  sheet_name: sheet_name,
119
- column_names: sheets_data["values"].first
123
+ column_names: column_names
120
124
  }
121
125
  end
122
126
  result
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "request_rate_limit": 6000,
3
3
  "request_rate_limit_unit": "minute",
4
- "request_rate_concurrency": 10,
4
+ "request_rate_concurrency": 1,
5
5
  "streams": []
6
6
  }
7
7
 
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "data": {
3
3
  "name": "Oracle",
4
- "title": "Oracle",
4
+ "title": "Oracle DB",
5
5
  "connector_type": "destination",
6
6
  "category": "Database",
7
7
  "documentation_url": "https://docs.squared.ai/guides/data-integration/destination/oracle",
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Multiwoven
4
4
  module Integrations
5
- VERSION = "0.8.1"
5
+ VERSION = "0.8.3"
6
6
 
7
7
  ENABLED_SOURCES = %w[
8
8
  Snowflake
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "data": {
3
3
  "name": "Databricks",
4
- "title": "Databricks",
4
+ "title": "Databricks Data Warehouse",
5
5
  "connector_type": "source",
6
6
  "category": "Data Warehouse",
7
7
  "documentation_url": "https://docs.mutliwoven.com",
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "data": {
3
3
  "name": "Oracle",
4
- "title": "Oracle",
4
+ "title": "Oracle DB",
5
5
  "connector_type": "source",
6
6
  "category": "Database",
7
7
  "documentation_url": "https://docs.squared.ai/guides/data-integration/source/oracle",
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: multiwoven-integrations
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.1
4
+ version: 0.8.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Subin T P
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-08-12 00:00:00.000000000 Z
11
+ date: 2024-08-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport