Giter Club home page Giter Club logo

Comments (10)

nzjony avatar nzjony commented on August 24, 2024 1

@trusktr , thanks again for looking into this.

I notice that we can simplify the interface, why should you need to specify the authenticationMethod, when the format could decide... or at least the format supplies a default authentication method, which could be this apikey, see getDefaultAuthMethod on OmvRestClient

I created an issue so that we can simplify this for others: #1390

from harp.gl.

engdevlab avatar engdevlab commented on August 24, 2024 1

method: harp.AuthenticationMethod.QueryString

from harp.gl.

trusktr avatar trusktr commented on August 24, 2024

I also just tried to make a REST app ID, then an API key for that, but no luck. For example:

GET https://xyz.api.here.com/tiles/herebase.02/14/12919/8134/omv?access_token=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX 401

from harp.gl.

trusktr avatar trusktr commented on August 24, 2024

Okay, looks like I actually need to go to HERE Studio Token Manager, not the regular Here app and api key manager, which can be confusing.

However, I've no idea how to generate a token. When I try, it says

No rights are selected for the token generation!

which isn't helpful.

from harp.gl.

trusktr avatar trusktr commented on August 24, 2024

I'm stuck here with no idea how to make a token to try the lib. Surely this is an annoying user experience for people who've tried what I'm trying. Don't take it personally, it's just that after spending the time to get Harp without Webpack, now I can't actually run the code for reasons unknown and not related to the code.

from harp.gl.

trusktr avatar trusktr commented on August 24, 2024

That UI is not intuitive: one needs to select check boxes in the table, which is seemingly unrelated to the popup form. This is a bad user experience because it is not obvious that checkboxes must be selected before opening the popup form. Those checkmarks seem like they are for managing entries in the tables, but there are no entries in the tables to begin with, so a person would not automatically think to start to interact with an empty table in order to start making tokens.

After I figured this out, I selected some check marks, and when I click the final Generate Token button in the popup window (after filling out the fields appropriately, as far as I know), nothing happens and the Google Chrome console shows the following error:

Uncaught TypeError: Cannot convert undefined or null to object
    at Function.entries (<anonymous>)
    at generateToken (tokenmatrixui.html:1277)
    at HTMLElement.onclick (tokenmatrixui.html:268)

:finnadie:

from harp.gl.

nzjony avatar nzjony commented on August 24, 2024

@trusktr , thanks for your bug report, and I apologize for your frustration.

We just recently changed away from xyz to the vector tile service, see: ae5f191

How did you generate the key, I guess you used this guide: https://github.com/heremaps/harp.gl/blob/master/docs/GettingStartedGuide.md#-here-credentials ?

If you change your baseUrl to the vector tile service, with the original key, does it work? See: https://github.com/heremaps/harp.gl/blob/master/docs/GettingStartedGuide.md#attach-data-source

Again sorry about this and thanks for your involvement!

from harp.gl.

trusktr avatar trusktr commented on August 24, 2024

Hello Jonathan, thanks for the help. I tried setting baseUrl to https://vector.hereapi.com/v2/vectortiles/base/mc, then I get the errors

GET https://vector.hereapi.com/v2/vectortiles/base/mc/14/12919/8133/omv?access_token=XXXXXXXXXXXXXXXXXXXXXX 401

with XXXXXXXXXXXXXXXXXXXXXX being the api key.

For reference, this is the page where that key came from,

here-project-details-javascript-api-key.

from harp.gl.

trusktr avatar trusktr commented on August 24, 2024

Ok! It worked. It needed the following (which ironically I realized in your comment in the Webpack issue).

        baseUrl: "https://vector.hereapi.com/v2/vectortiles/base/mc",
        authenticationCode: "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
        authenticationMethod: { // <------------------------ This was missing.
            method: AuthenticationMethod.QueryString,
            name: "apikey"
        },

:godmode:

from harp.gl.

stale avatar stale commented on August 24, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from harp.gl.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.