Skip to content

Commit d834492

Browse files
committed
rearrage package structure
1 parent 7df074c commit d834492

File tree

110 files changed

+101
-11982
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

110 files changed

+101
-11982
lines changed

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
.DS_Store
2+
.venv*
3+
.vscode
4+
**/*.pyc
5+
**/dist
6+
17
# Byte-compiled / optimized / DLL files
28
__pycache__/
39
*.py[cod]

LICENSE.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
Copyright (c) 2020, Narrative Science
2+
3+
All rights reserved.
4+
5+
Redistribution and use in source and binary forms, with or without
6+
modification, are permitted provided that the following conditions are met:
7+
8+
- Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
9+
- Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
10+
- Neither the name of the <organization> nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
11+
12+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
13+
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
14+
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
15+
DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
16+
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
17+
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
18+
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
19+
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
20+
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
21+
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

README.md

Lines changed: 24 additions & 121 deletions
Original file line numberDiff line numberDiff line change
@@ -1,139 +1,42 @@
1-
# openapi-client
2-
https://www.stitchdata.com/docs/developers/stitch-connect/api
1+
# stitch-connect-client
32

4-
This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
3+
[![](https://img.shields.io/pypi/v/stitch-connect-client.svg)](https://pypi.org/pypi/stitch-connect-client/) [![License](https://img.shields.io/badge/License-BSD%203--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause)
54

6-
- API version: 0.1
7-
- Package version: 1.0.0
8-
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
5+
<!-- Short description of the package -->
96

10-
## Requirements.
7+
Features:
118

12-
Python 2.7 and 3.4+
9+
- <!-- list of features -->
1310

14-
## Installation & Usage
15-
### pip install
11+
Table of Contents:
1612

17-
If the python package is hosted on a repository, you can install directly using:
13+
- [Installation](#installation)
14+
- [Guide](#guide)
15+
- [Development](#development)
1816

19-
```sh
20-
pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git
21-
```
22-
(you may need to run `pip` with root permission: `sudo pip install git+https://github.com/GIT_USER_ID/GIT_REPO_ID.git`)
23-
24-
Then import the package:
25-
```python
26-
import openapi_client
27-
```
17+
## Installation
2818

29-
### Setuptools
30-
31-
Install via [Setuptools](http://pypi.python.org/pypi/setuptools).
32-
33-
```sh
34-
python setup.py install --user
35-
```
36-
(or `sudo python setup.py install` to install the package for all users)
19+
stitch-connect-client requires Python 3.6 or above.
3720

38-
Then import the package:
39-
```python
40-
import openapi_client
21+
```bash
22+
pip install stitch-connect-client
4123
```
4224

43-
## Getting Started
25+
## Guide
4426

45-
Please follow the [installation procedure](#installation--usage) and then run the following:
27+
<!-- Subsections explaining how to use the package -->
4628

47-
```python
48-
from __future__ import print_function
49-
import time
50-
import openapi_client
51-
from openapi_client.rest import ApiException
52-
from pprint import pprint
29+
## Development
5330

54-
configuration = openapi_client.Configuration()
55-
# Configure Bearer authorization: bearerAuth
56-
configuration.access_token = 'YOUR_BEARER_TOKEN'
57-
58-
# Defining host is optional and default to https://stitchdata.com
59-
configuration.host = "https://stitchdata.com"
60-
# Create an instance of the API class
61-
api_instance = openapi_client.DestinationsApi(openapi_client.ApiClient(configuration))
62-
destination_info = openapi_client.DestinationInfo() # DestinationInfo | Object containing type and properties of a destination (optional)
63-
64-
try:
65-
# Creates a new destination. Only a single destination is supported per Stitch client account.
66-
api_instance.create_destination(destination_info=destination_info)
67-
except ApiException as e:
68-
print("Exception when calling DestinationsApi->create_destination: %s\n" % e)
31+
To develop stitch-connect-client, install dependencies and enable the pre-commit hook:
6932

33+
```bash
34+
pip install pre-commit tox
35+
pre-commit install
7036
```
7137

72-
## Documentation for API Endpoints
73-
74-
All URIs are relative to *https://stitchdata.com*
75-
76-
Class | Method | HTTP request | Description
77-
------------ | ------------- | ------------- | -------------
78-
*DestinationsApi* | [**create_destination**](docs/DestinationsApi.md#create_destination) | **POST** /v4/destinations | Creates a new destination. Only a single destination is supported per Stitch client account.
79-
*DestinationsApi* | [**delete_destination**](docs/DestinationsApi.md#delete_destination) | **DELETE** /v4/destinations/{destination_id} | Deletes an existing destination. Note: Stitch requires a destination to replicate data. Replication will be paused until a new destination is created and has a successful connection.
80-
*DestinationsApi* | [**get_destination_types**](docs/DestinationsApi.md#get_destination_types) | **GET** /v4/destination-types | Retrieves general information about the configuration required for all supported destination types.
81-
*DestinationsApi* | [**get_destinations**](docs/DestinationsApi.md#get_destinations) | **GET** /v4/destinations | Lists the destination currently in use for a Stitch account. Only a single data warehouse is supported per Stitch client account.
82-
*DestinationsApi* | [**update_destination**](docs/DestinationsApi.md#update_destination) | **PUT** /v4/destinations/{destination_id} | Updates an existing destination. Modifications to the type attribute are not supported.
83-
*SourcesApi* | [**create_source**](docs/SourcesApi.md#create_source) | **POST** /v4/sources | Creates a source object, which is the first step in setting up a new data source. After the source object is created, additional configuration steps must be completed.
84-
*SourcesApi* | [**delete_source**](docs/SourcesApi.md#delete_source) | **DELETE** /v4/sources/{source_id} | Deletes an existing data source.
85-
*SourcesApi* | [**get_last_connection_check**](docs/SourcesApi.md#get_last_connection_check) | **GET** /v4/sources/{source_id}/last-connection-check | Retrieves the last connection check for a source by the source’s unique identifier.
86-
*SourcesApi* | [**get_source**](docs/SourcesApi.md#get_source) | **GET** /v4/sources/{source_id} | Retrieves a previously created data source by its unique identifier. This endpoint can be used to retrieve an active, paused, or deleted source.
87-
*SourcesApi* | [**get_sources**](docs/SourcesApi.md#get_sources) | **GET** /v4/sources | Lists the sources for an account, including active, paused, and deleted sources.
88-
*SourcesApi* | [**start_replication**](docs/SourcesApi.md#start_replication) | **POST** /v4/sources/{source_id}/sync | Manually starts a replication job for a source using the source’s unique identifier.
89-
*SourcesApi* | [**update_source**](docs/SourcesApi.md#update_source) | **PUT** /v4/sources/{source_id} | Updates an existing data source.
90-
*StreamsApi* | [**get_stream_schema**](docs/StreamsApi.md#get_stream_schema) | **GET** /v4/sources/{source_id}/streams/{stream_id} | Retrieves the schema for a source’s stream by the source and stream’s unique identifiers.
91-
*StreamsApi* | [**get_streams**](docs/StreamsApi.md#get_streams) | **GET** /v4/sources/{source_id}/streams | Lists the available streams for a source.
92-
*StreamsApi* | [**update_stream_metadata**](docs/StreamsApi.md#update_stream_metadata) | **PUT** /v4/sources/{source_id}/streams/metadata | Updates the metadata for streams and fields. This endpoint is used to define the metadata properties returned in the Stream Schema object’s non-discoverable-metadata-keys property.
93-
94-
95-
## Documentation For Models
96-
97-
- [AzureDestinationFormProperties](docs/AzureDestinationFormProperties.md)
98-
- [ConnectionCheck](docs/ConnectionCheck.md)
99-
- [ConnectionDetails](docs/ConnectionDetails.md)
100-
- [ConnectionStep](docs/ConnectionStep.md)
101-
- [ConnectionStepProps](docs/ConnectionStepProps.md)
102-
- [ConnectionStepPropsAnyOf](docs/ConnectionStepPropsAnyOf.md)
103-
- [ConnectionStepPropsJsonSchema](docs/ConnectionStepPropsJsonSchema.md)
104-
- [CreateSourceBody](docs/CreateSourceBody.md)
105-
- [Destination](docs/Destination.md)
106-
- [DestinationFormProperties](docs/DestinationFormProperties.md)
107-
- [DestinationInfo](docs/DestinationInfo.md)
108-
- [DestinationReportCard](docs/DestinationReportCard.md)
109-
- [ErrorObject](docs/ErrorObject.md)
110-
- [ErrorObjectError](docs/ErrorObjectError.md)
111-
- [FieldLevelMetadata](docs/FieldLevelMetadata.md)
112-
- [HookNotification](docs/HookNotification.md)
113-
- [HookNotificationConfig](docs/HookNotificationConfig.md)
114-
- [Metadata](docs/Metadata.md)
115-
- [ReplicationJob](docs/ReplicationJob.md)
116-
- [S3DestinationFormProperties](docs/S3DestinationFormProperties.md)
117-
- [SalesforceSourceFormProperties](docs/SalesforceSourceFormProperties.md)
118-
- [Source](docs/Source.md)
119-
- [SourceFormProperties](docs/SourceFormProperties.md)
120-
- [SourceReportCard](docs/SourceReportCard.md)
121-
- [Stream](docs/Stream.md)
122-
- [StreamLevelMetadata](docs/StreamLevelMetadata.md)
123-
- [StreamSchema](docs/StreamSchema.md)
124-
- [UpdateSourceBody](docs/UpdateSourceBody.md)
125-
126-
127-
## Documentation For Authorization
128-
129-
130-
## bearerAuth
131-
132-
- **Type**: Bearer authentication
133-
134-
135-
## Author
136-
137-
138-
38+
To run tests:
13939

40+
```bash
41+
tox
42+
```

docs/AzureDestinationFormProperties.md

Lines changed: 0 additions & 13 deletions
This file was deleted.

docs/ConnectionCheck.md

Lines changed: 0 additions & 12 deletions
This file was deleted.

docs/ConnectionDetails.md

Lines changed: 0 additions & 16 deletions
This file was deleted.

docs/ConnectionStep.md

Lines changed: 0 additions & 12 deletions
This file was deleted.

docs/ConnectionStepProps.md

Lines changed: 0 additions & 16 deletions
This file was deleted.

docs/ConnectionStepPropsAnyOf.md

Lines changed: 0 additions & 11 deletions
This file was deleted.

docs/ConnectionStepPropsJsonSchema.md

Lines changed: 0 additions & 12 deletions
This file was deleted.

0 commit comments

Comments
 (0)