Skip to content

Commit bc01248

Browse files
authored
source-plausible new config setting for self hosted plausible instance. (#43048)
1 parent 4bcf36c commit bc01248

File tree

4 files changed

+27
-4
lines changed

4 files changed

+27
-4
lines changed

airbyte-integrations/connectors/source-plausible/metadata.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ data:
1616
connectorSubtype: api
1717
connectorType: source
1818
definitionId: 603ba446-3d75-41d7-92f3-aba901f8b897
19-
dockerImageTag: 0.1.11
19+
dockerImageTag: 0.1.12
2020
dockerRepository: airbyte/source-plausible
2121
githubIssueLabel: source-plausible
2222
icon: plausible.svg

airbyte-integrations/connectors/source-plausible/pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ requires = [ "poetry-core>=1.0.0",]
33
build-backend = "poetry.core.masonry.api"
44

55
[tool.poetry]
6-
version = "0.1.11"
6+
version = "0.1.12"
77
name = "source-plausible"
88
description = "Source implementation for Plausible."
99
authors = [ "Airbyte <[email protected]>",]

airbyte-integrations/connectors/source-plausible/source_plausible/manifest.yaml

+12-2
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ definitions:
4040
$ref: "#/schemas/stats"
4141
base_requester:
4242
type: HttpRequester
43-
url_base: https://plausible.io/api/v1/stats
43+
url_base: "{{ config['api_url'] or 'https://plausible.io/api/v1/stats' }}"
4444
authenticator:
4545
type: BearerAuthenticator
4646
api_token: "{{ config['api_key'] }}"
@@ -79,14 +79,24 @@ spec:
7979
- airbyte.com
8080
- docs.airbyte.com
8181
order: 1
82+
api_url:
83+
type: string
84+
title: API URL
85+
description: >-
86+
The API URL of your plausible instance.
87+
Change this if you self-host plausible. The default is https://plausible.io/api/v1/stats
88+
pattern: ^[A-Za-z0-9-.]+\.[A-Z-a-z0-9-.]+
89+
examples:
90+
- https://plausible.example.com/api/v1/stats
91+
order: 2
8292
start_date:
8393
type: string
8494
title: Data start date
8595
description: Start date for data to retrieve, in ISO-8601 format.
8696
pattern: ^[0-9]{4}-[0-9]{2}-[0-9]{2}$
8797
examples:
8898
- YYYY-MM-DD
89-
order: 2
99+
order: 3
90100
additionalProperties: true
91101

92102
metadata:

docs/integrations/sources/plausible.md

+13
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,18 @@
1616

1717
- [Stats - Time Series](https://plausible.io/docs/stats-api#get-apiv1statstimeseries)
1818

19+
## Setup steps
20+
1. [Log into your Airbyte Cloud](https://cloud.airbyte.com/workspaces) account or navigate to the Airbyte Open Source dashboard.
21+
2. Click **Sources** and then click **+ New source**.
22+
3. On the Set up the source page, select **Plausible** from the Source type dropdown.
23+
4. Enter a name for the connector
24+
5. Enter the following configurations:
25+
- **API Key**: Plausible API Key. See the <a href="https://plausible.io/docs/stats-api">docs</a> for information on how to generate this key.
26+
- **Site ID**: The domain of the site you want to retrieve data for. Enter the name of your site as configured on Plausible, i.e., excluding "https://" and "www". Can be retrieved from the 'domain' field in your Plausible site settings.
27+
- **API URL**: The API URL of your plausible instance. Change this if you self-host plausible. Otherwise it will default to https://plausible.io/api/v1/stats
28+
- **start_date**: Data start date Start date for data to retrieve, in ISO-8601 format.
29+
30+
1931
### Notes
2032

2133
Plausible is a privacy-first analytics service, and the data available from its API is intentionally 1) less granular and 2) less comprehensive than those available from Google Analytics. As such:
@@ -36,6 +48,7 @@ The [stated rate limit](https://plausible.io/docs/stats-api) is 600 requests per
3648

3749
| Version | Date | Pull Request | Subject |
3850
|:--------|:-----------| :------------------------------------------------------- | :------------- |
51+
| 0.1.12 | 2024-08-06 | [42793](https://github.com/airbytehq/airbyte/pull/43048) | new API URL config option available |
3952
| 0.1.11 | 2024-08-03 | [43252](https://github.com/airbytehq/airbyte/pull/43252) | Update dependencies |
4053
| 0.1.10 | 2024-07-27 | [42793](https://github.com/airbytehq/airbyte/pull/42793) | Update dependencies |
4154
| 0.1.9 | 2024-07-20 | [41918](https://github.com/airbytehq/airbyte/pull/41918) | Update dependencies |

0 commit comments

Comments
 (0)