fidor_starter_kits 0.7.0 → 0.7.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -2
- data/lib/fidor_starter_kits/version.rb +1 -1
- data/starter_kits/golang_transactions/example.go +2 -2
- data/starter_kits/php_advanced/demo/dashboard.php +3 -3
- data/starter_kits/php_oauth_plain/example.php +3 -3
- data/starter_kits/ruby_oauth_plain/example.rb +8 -8
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 29344003a5c099b2ead06f74b4bedb6c094fdf7772b20fab40b4b4af465618d9
|
4
|
+
data.tar.gz: ecc18c8858add69e55fdf41772106072e6613044678e9f6e3b5f9e46a38bd3d2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: afef4dc0b18c57964aa4b69dd847503f367e609c20b5bf6a50d080e85cbc0e1e3b2d96e60f60ea6c6c8523b038ab0d9deb6a35b6c0b89aa4acbc644e77373b9e
|
7
|
+
data.tar.gz: f2f6c97e74fbb7911f157ae88cb811debc1af7d4fa2fba085828c3a9cb06d3070a5afa6a900eca75e6ec80b12ec2262ad5c5f5bf956099b4f352d8603dffcfcc
|
data/README.md
CHANGED
@@ -59,8 +59,8 @@ example.xy file are substituted with the according values from the app
|
|
59
59
|
<APP_URL> # default http://localhost:8000/example.php
|
60
60
|
<CLIENT_ID>
|
61
61
|
<CLIENT_SECRET>
|
62
|
-
<FIDOR_OAUTH_URL> # e.g Sandbox: https://
|
63
|
-
<FIDOR_API_URL> # e.g Sandbox: https://
|
62
|
+
<FIDOR_OAUTH_URL> # e.g Sandbox: https://apm.sandbox.fidor.com/oauth / Live: https://apm.fidor.de/oauth
|
63
|
+
<FIDOR_API_URL> # e.g Sandbox: https://api.sandbox.fidor.com / Live: https://api.fidor.de
|
64
64
|
|
65
65
|
So just add those to example.[rb, php, ..] and see existing examples and specs
|
66
66
|
for a reference.
|
@@ -30,8 +30,8 @@ type Config struct {
|
|
30
30
|
AppUrl string // where to reach this application
|
31
31
|
ClientId string // OAuth Client_id parameter
|
32
32
|
ClientSecret string // OAuth Client_secret parameter
|
33
|
-
FidorApiUrl string // API endpoint e.g Sandbox: https://
|
34
|
-
FidorOauthUrl string // OAuth endpoint e.g Sandbox: https://
|
33
|
+
FidorApiUrl string // API endpoint e.g Sandbox: https://api.sandbox.fidor.com / Live: https://apm.fidor.de
|
34
|
+
FidorOauthUrl string // OAuth endpoint e.g Sandbox: https://apm.sandbox.fidor.com/oauth / Live: https://api.fidor.de/oauth
|
35
35
|
}
|
36
36
|
|
37
37
|
var fidorConfig = Config{
|
@@ -79,13 +79,13 @@ if ( ! empty( $accounts['message'] ) ) {
|
|
79
79
|
|
80
80
|
<p>
|
81
81
|
Congratulation, here’s your access-token, I will use it for all theAPI calls: <strong><?php echo $_SESSION['oauth']['access_token']; ?></strong>. <br />
|
82
|
-
It will expire on <strong><?php echo gmdate( 'r', ( $_SESSION['oauth']['auth_at']+$_SESSION['oauth']['expires_in'] ) ); ?></strong>.
|
83
|
-
The refresh-token is <strong><?php echo $_SESSION['oauth']['refresh_token']; ?></strong>. You can use it to request a
|
82
|
+
It will expire on <strong><?php echo gmdate( 'r', ( $_SESSION['oauth']['auth_at']+$_SESSION['oauth']['expires_in'] ) ); ?></strong>.<br /><br />
|
83
|
+
The refresh-token is <strong><?php echo $_SESSION['oauth']['refresh_token']; ?></strong>. You can use it to request anew access-token.
|
84
84
|
</p>
|
85
85
|
|
86
86
|
<h2>Data access</h2>
|
87
87
|
<p>
|
88
|
-
Cool, I have access to this account (GET
|
88
|
+
Cool, I have access to this account (GET api.sandbox.fidor.com/accounts):
|
89
89
|
</p>
|
90
90
|
|
91
91
|
<?php
|
@@ -3,8 +3,8 @@
|
|
3
3
|
$app_url = "<APP_URL>"; # default http://localhost:8000/example.php
|
4
4
|
$app_id = "<CLIENT_ID>";
|
5
5
|
$app_secret = "<CLIENT_SECRET>";
|
6
|
-
$fidor_oauth_url= "<FIDOR_OAUTH_URL>"; # e.g Sandbox: https://
|
7
|
-
$fidor_api_url = "<FIDOR_API_URL>"; # e.g Sandbox: https://
|
6
|
+
$fidor_oauth_url= "<FIDOR_OAUTH_URL>"; # e.g Sandbox: https://apm.sandbox.fidor.com/oauth / Live: https://apm.fidor.de/oauth
|
7
|
+
$fidor_api_url = "<FIDOR_API_URL>"; # e.g Sandbox: https://api.sandbox.fidor.com / Live: https://api.fidor.de
|
8
8
|
|
9
9
|
$code = $_REQUEST["code"];
|
10
10
|
|
@@ -52,4 +52,4 @@ if(empty($code) || $code == '') {
|
|
52
52
|
<blockquote>curl -v -H \"Authorization: Bearer ".$resp->access_token."\" -H \"Accept: application/vnd.fidor.de; version=1,text/json\" ".$fidor_api_url."/transactions
|
53
53
|
</blockquote>");
|
54
54
|
}
|
55
|
-
?>
|
55
|
+
?>
|
@@ -7,8 +7,8 @@ get '/' do
|
|
7
7
|
@app_url = '<APP_URL>' # default for local installs: http://localhost:4567
|
8
8
|
@client_id = '<CLIENT_ID>'
|
9
9
|
@client_secret = '<CLIENT_SECRET>'
|
10
|
-
@fidor_oauth_url = '<FIDOR_OAUTH_URL>' # e.g Sandbox: https://
|
11
|
-
@fidor_api_url = '<FIDOR_API_URL>' # e.g Sandbox: https://
|
10
|
+
@fidor_oauth_url = '<FIDOR_OAUTH_URL>' # e.g Sandbox: https://apm.sandbox.fidor.com/oauth / Live: https://apm.fidor.de/oauth
|
11
|
+
@fidor_api_url = '<FIDOR_API_URL>' # e.g Sandbox: https://api.sandbox.fidor.com / Live: https://api.fidor.de
|
12
12
|
|
13
13
|
# 1. redirect to authorize url
|
14
14
|
unless code = params["code"]
|
@@ -32,14 +32,14 @@ get '/' do
|
|
32
32
|
|
33
33
|
"<h2>Hello #{user['email']}</h2>
|
34
34
|
<i>May i present the access token response:</i>
|
35
|
-
<
|
35
|
+
<pre><code>#{resp.body}</code></pre>
|
36
36
|
<p>Now use the access token in the Header of your Requests, e.g. using CURL</p>
|
37
37
|
<h3>GET /accounts</h3>
|
38
|
-
<
|
38
|
+
<pre><code>
|
39
39
|
curl -v --header \"Accept: application/vnd.fidor.de; version=1,text/json\" --header \"Authorization: Bearer #{resp['access_token']}\" #{@fidor_api_url}/accounts
|
40
|
-
</
|
41
|
-
|
42
|
-
|
40
|
+
</code></pre>
|
41
|
+
<h3>GET /transactions</h3>
|
42
|
+
<pre><code>
|
43
43
|
curl -v --header \"Accept: application/vnd.fidor.de; version=1,text/json\" --header \"Authorization: Bearer #{resp['access_token']}\" #{@fidor_api_url}/transactions?per_page=5
|
44
|
-
|
44
|
+
</code></pre>"
|
45
45
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fidor_starter_kits
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fidor Solutions AG
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-08-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rubyzip
|