Skip to content

Commit

Permalink
Merge pull request #12 from konnectors/pagination
Browse files Browse the repository at this point in the history
Add account_types definition & albums pagination
  • Loading branch information
doubleface authored Apr 26, 2018
2 parents 445def5 + b029209 commit 669c031
Show file tree
Hide file tree
Showing 12 changed files with 677 additions and 344 deletions.
28 changes: 18 additions & 10 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,26 +3,34 @@ node_js:
- '8'
env:
global:
# doubleface GITHUB_TOKEN
# to generate yours : travis encrypt GITHUB_TOKEN=<your_GITHUB_TOKEN> -r konnectors/cozy-konnector-facebook
- secure: "kAu45Cgy+nnGck6rUqZrWwXhV+sdf8wTrYrcLkSDx/40eyLCOHPWwLYKcEaveIjaFqXR+LKsise1yeztHKmkrh8c48uTNqBnsWv7NsAHzg3O/rSW64J0HWo+yItJVbX7Cxz0v3RRorf5Jea0WPk8HF2zbcerJYHDNpqIMe7FAQiEzM4JOqb5bjQgrRuxeuMFT6QSQKVmzZp/bJnMQ8GLkH4Mi2m6213XYEt8strPdkn1u6j9b0vAKJSVbscOb+3Wo1f1PqKIDhhKo3h7KO27PZAzdGCJOwirn8yHeiLGwXXolytLRYpitFEuQRCeITbJXLUFtdEaAQbRb3lPDkOZJJXNNaRNlNafFpz0K/K/hqYQlKX8UeStS5rA13GIY1fAsLedHC0DkYSAhkxAakn2muy7dLAIsvVujmu0H0n8wcEKSik8Pd8XAg/taMev3jpSkHoulfMtbK/Utvwtj6vFkrZOV2sh7AjVkBq3cxO+odNEs4iJ4EFHlQDXzCOg/QgkO+3/w29BvbpTP2PT9n9TcJcCtJo0Y/1rOYvvcvRhUibgaKRCYXVO4BmxiJw1KGnwp7vObnJ2RyfJwgfbeXpO+Ej76Vqm2ewHUBD/2XbyFhzv0PJ3HE+w1iGyVLQgNYmrFmmot8uQPy1EHnrwaCZYg1HGTrA6I8TrCxk5D+sWr4o="
- secure: ZA9OZhsWQQcHGIv3L+FOj4SGKd231a1h3ghoKWaKiR9nRKLI5jrvV20zhioO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l0ja3qgE0rRzO4ab6QMQ39q8GDLzD8hX8FR1hv/tbS17LkMSIRg/Y4nppekVlN+Ji5bwnaKADZhEyC+OXjZwessVZJNsY/fwTbCaLpba3cWajp//4d45P7kOS0+NKFGruUXvMOo7bBBHZzDmmzDj2nXtn/AEhI6PMnoQ0OE2NhkRD48lMPEvS60p5lyKLMbdGVvfs1UYzh2aDwmxUqDMpbbPc1Qyt2yUQqEzODUOWckiTkpwE=
cache:
yarn: true
directories:
- node_modules
- node_modules
script:
- yarn lint
- yarn build
- yarn lint
- yarn build
deploy:
# publish dev versions
- provider: script
repo: $TRAVIS_REPO_SLUG
repo: konnectors/cozy-konnector-facebook
skip-cleanup: true
script: yarn deploy
script: DEPLOY_BRANCH=build && yarn deploy && yarn cozyPublish
on:
branch: master
# publish on latest branch (will be removed when collect will use only the registry
- provider: script
repo: $TRAVIS_REPO_SLUG
repo: konnectors/cozy-konnector-facebook
skip-cleanup: true
script: DEPLOY_BRANCH=latest yarn deploy
script: DEPLOY_BRANCH=latest && yarn deploy
on:
branch: prod
# publish stable versions and beta versions based on tags
- provider: script
repo: konnectors/cozy-konnector-facebook
skip-cleanup: true
script: DEPLOY_BRANCH=build && yarn deploy && yarn cozyPublish
on:
tags: true
10 changes: 10 additions & 0 deletions account-types-def.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"_id": "facebook",
"grant_mode": "authorization_code",
"redirect_uri": "https://oauthcallback.cozy.tools/accounts/facebook/redirect",
"token_mode": "basic",
"token_endpoint": "https://graph.facebook.com/v2.12/oauth/access_token",
"auth_endpoint": "https://www.facebook.com/v2.12/dialog/oauth",
"client_id": "$COZY_FB_CLIENT_ID",
"client_secret": "$COZY_FB_CLIENT_SECRET"
}
13 changes: 13 additions & 0 deletions assets/icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
180 changes: 0 additions & 180 deletions facebookHelper.js

This file was deleted.

13 changes: 13 additions & 0 deletions icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 0 additions & 27 deletions key.pem

This file was deleted.

70 changes: 55 additions & 15 deletions manifest.konnector
Original file line number Diff line number Diff line change
@@ -1,36 +1,76 @@
{
"version": "0.1.0",
"version": "1.0.0",
"name": "Facebook",
"type": "node",
"type": "konnector",
"language": "node",
"slug": "facebook",
"icon": "icon.svg",
"source": "git://github.com/konnectors/cozy-konnector-facebook.git",
"locales": {
"fr": {
"description":
"Reprend la main sur vos données que vous avez données à Facebook : contacts, photos",
"permissions": {
"contacts": {
"description": "Exigée pour sauvegarder les contacts"
}
"editor": "Cozy",
"vendor_link": "https://facebook.com",
"categories": ["other"],
"data_types": ["pictures"],
"oauth": {
"account_type": "facebook",
"scope": "user_photos"
},
"fields": {
"advancedFields": {
"folderPath": {
"advanced": true,
"isRequired": false
}
}
},
"permissions": {
"albums": {
"description": "Required to create the albums where the photo will be saved",
"type": "io.cozy.photos.albums"
},
"accounts": {
"description": "Required to get the account's data",
"type": "io.cozy.accounts"
},
"files": {
"description": "Required to save images",
"type": "io.cozy.files"
}
},
"locales": {
"fr": {
"short_description": "Connecteur Facebook",
"long_description": "Ce connecteur récupère les albums photos que vous avez publiés sur facebook.",
"permissions": {
"books": {
"description": "Utilisé pour créer les albums ou sont sauvegardées les photos."
},
"files": {
"description": "Utilisé pour sauvegarder les photos."
},
"accounts": {
"description": "Utilisé pour obtenir les données du compte"
}
}
},
"en": {
"short_description": "Connector Facebook",
"long_description": "This connector retrieves your facebook pictures albums.",
"permissions": {
"albums": {
"description": "Required to create the albums where the photo will be saved",
"type": "io.cozy.photos.albums"
},
"accounts": {
"description": "Required to get the account's data",
"type": "io.cozy.accounts"
},
"files": {
"description": "Required to save images",
"type": "io.cozy.files"
}
}
}
},
"langs": ["fr", "en"],
"developer": {
"name": "cozy",
"url": "cozy.io"
"name": "Cozy",
"url": "https://cozy.io"
}
}
Loading

0 comments on commit 669c031

Please sign in to comment.