Evernote SDK Java: SHARD_UNAVAILABLE while authenticating to Shared Notebook
I am attempting to authenticate to Shared Notebook to extract Notes from it. But I am receiving EDAMSystemException with Error Code: "SHARD_UNAVAILABLE". While debugging it, I noticed that the ShardId of my account and the ShardId of the Shared Notebook is different.
This never happened while Testing in the Sandbox Account(Currently Testing it in Production). Below is the code:
List<LinkedNotebook> linkedNotebooks = noteStore.listLinkedNotebook();
for(LinkedNotebook linkedNotebook: linkedNotebooks){
String sharkey = linkedNotebook.getShareKey();
String share_token = noteStore.authenticateToSharedNotebook(sharekey).getAuthenticationToken();
System.out.println("Share Token:" +shareToken)
}
Would be great if anybody helps me out with this issue.
java evernote
add a comment |
I am attempting to authenticate to Shared Notebook to extract Notes from it. But I am receiving EDAMSystemException with Error Code: "SHARD_UNAVAILABLE". While debugging it, I noticed that the ShardId of my account and the ShardId of the Shared Notebook is different.
This never happened while Testing in the Sandbox Account(Currently Testing it in Production). Below is the code:
List<LinkedNotebook> linkedNotebooks = noteStore.listLinkedNotebook();
for(LinkedNotebook linkedNotebook: linkedNotebooks){
String sharkey = linkedNotebook.getShareKey();
String share_token = noteStore.authenticateToSharedNotebook(sharekey).getAuthenticationToken();
System.out.println("Share Token:" +shareToken)
}
Would be great if anybody helps me out with this issue.
java evernote
add a comment |
I am attempting to authenticate to Shared Notebook to extract Notes from it. But I am receiving EDAMSystemException with Error Code: "SHARD_UNAVAILABLE". While debugging it, I noticed that the ShardId of my account and the ShardId of the Shared Notebook is different.
This never happened while Testing in the Sandbox Account(Currently Testing it in Production). Below is the code:
List<LinkedNotebook> linkedNotebooks = noteStore.listLinkedNotebook();
for(LinkedNotebook linkedNotebook: linkedNotebooks){
String sharkey = linkedNotebook.getShareKey();
String share_token = noteStore.authenticateToSharedNotebook(sharekey).getAuthenticationToken();
System.out.println("Share Token:" +shareToken)
}
Would be great if anybody helps me out with this issue.
java evernote
I am attempting to authenticate to Shared Notebook to extract Notes from it. But I am receiving EDAMSystemException with Error Code: "SHARD_UNAVAILABLE". While debugging it, I noticed that the ShardId of my account and the ShardId of the Shared Notebook is different.
This never happened while Testing in the Sandbox Account(Currently Testing it in Production). Below is the code:
List<LinkedNotebook> linkedNotebooks = noteStore.listLinkedNotebook();
for(LinkedNotebook linkedNotebook: linkedNotebooks){
String sharkey = linkedNotebook.getShareKey();
String share_token = noteStore.authenticateToSharedNotebook(sharekey).getAuthenticationToken();
System.out.println("Share Token:" +shareToken)
}
Would be great if anybody helps me out with this issue.
java evernote
java evernote
edited Jan 1 at 23:27
Ben Zotto
49.8k21126193
49.8k21126193
asked Dec 7 '18 at 14:33
Aniruddha BhajanAniruddha Bhajan
11
11
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
You need to authenticate to the shared notebook using a note store client object that is specific to that linked notebook, not the default one that you're using. A note store client "points" to a particular note store and can only access data on that store. All of a user's own personal data lives inside one note store, and that's the main note store client that you have created there as noteStore
.
Accessing each linked notebook requires creating a new note store client object that is a "client" of the place where that linked notebook lives. There's enough information to do this inside the LinkedNotebook
object you have there but there are a couple additional steps.
You may want to take a look at this question/answer. You can use the information inside the LinkedNotebook object to create a new note store client that points to where the corresponding shared notebook lives. Then use that note store to authenticate to the shared notebook there. In short: you'll get the note store URL from the linked notebook record, then use that plus your existing auth token to create a new note store client to the shared notebook and authenticate to it.
Syntax (and complexity) may vary depending on your specific platform and SDK version. Maybe see also this page for some conceptual help.
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53671604%2fevernote-sdk-java-shard-unavailable-while-authenticating-to-shared-notebook%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
You need to authenticate to the shared notebook using a note store client object that is specific to that linked notebook, not the default one that you're using. A note store client "points" to a particular note store and can only access data on that store. All of a user's own personal data lives inside one note store, and that's the main note store client that you have created there as noteStore
.
Accessing each linked notebook requires creating a new note store client object that is a "client" of the place where that linked notebook lives. There's enough information to do this inside the LinkedNotebook
object you have there but there are a couple additional steps.
You may want to take a look at this question/answer. You can use the information inside the LinkedNotebook object to create a new note store client that points to where the corresponding shared notebook lives. Then use that note store to authenticate to the shared notebook there. In short: you'll get the note store URL from the linked notebook record, then use that plus your existing auth token to create a new note store client to the shared notebook and authenticate to it.
Syntax (and complexity) may vary depending on your specific platform and SDK version. Maybe see also this page for some conceptual help.
add a comment |
You need to authenticate to the shared notebook using a note store client object that is specific to that linked notebook, not the default one that you're using. A note store client "points" to a particular note store and can only access data on that store. All of a user's own personal data lives inside one note store, and that's the main note store client that you have created there as noteStore
.
Accessing each linked notebook requires creating a new note store client object that is a "client" of the place where that linked notebook lives. There's enough information to do this inside the LinkedNotebook
object you have there but there are a couple additional steps.
You may want to take a look at this question/answer. You can use the information inside the LinkedNotebook object to create a new note store client that points to where the corresponding shared notebook lives. Then use that note store to authenticate to the shared notebook there. In short: you'll get the note store URL from the linked notebook record, then use that plus your existing auth token to create a new note store client to the shared notebook and authenticate to it.
Syntax (and complexity) may vary depending on your specific platform and SDK version. Maybe see also this page for some conceptual help.
add a comment |
You need to authenticate to the shared notebook using a note store client object that is specific to that linked notebook, not the default one that you're using. A note store client "points" to a particular note store and can only access data on that store. All of a user's own personal data lives inside one note store, and that's the main note store client that you have created there as noteStore
.
Accessing each linked notebook requires creating a new note store client object that is a "client" of the place where that linked notebook lives. There's enough information to do this inside the LinkedNotebook
object you have there but there are a couple additional steps.
You may want to take a look at this question/answer. You can use the information inside the LinkedNotebook object to create a new note store client that points to where the corresponding shared notebook lives. Then use that note store to authenticate to the shared notebook there. In short: you'll get the note store URL from the linked notebook record, then use that plus your existing auth token to create a new note store client to the shared notebook and authenticate to it.
Syntax (and complexity) may vary depending on your specific platform and SDK version. Maybe see also this page for some conceptual help.
You need to authenticate to the shared notebook using a note store client object that is specific to that linked notebook, not the default one that you're using. A note store client "points" to a particular note store and can only access data on that store. All of a user's own personal data lives inside one note store, and that's the main note store client that you have created there as noteStore
.
Accessing each linked notebook requires creating a new note store client object that is a "client" of the place where that linked notebook lives. There's enough information to do this inside the LinkedNotebook
object you have there but there are a couple additional steps.
You may want to take a look at this question/answer. You can use the information inside the LinkedNotebook object to create a new note store client that points to where the corresponding shared notebook lives. Then use that note store to authenticate to the shared notebook there. In short: you'll get the note store URL from the linked notebook record, then use that plus your existing auth token to create a new note store client to the shared notebook and authenticate to it.
Syntax (and complexity) may vary depending on your specific platform and SDK version. Maybe see also this page for some conceptual help.
edited Jan 1 at 23:31
answered Jan 1 at 23:24
Ben ZottoBen Zotto
49.8k21126193
49.8k21126193
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53671604%2fevernote-sdk-java-shard-unavailable-while-authenticating-to-shared-notebook%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown