manifest.json "private"

Comments

7 comments

  • Avatar
    Jeff Tanner

    Note: I would like to use the manifest.json "private" to determine if my Lotus App is within development mode (debug and tracing) or production mode.

    • Jeff
  • Avatar
    James A. Rosen

    My guess is that what you have might be valid JavaScript, but not valid JSON. In JSON, all keys must be Strings. "private": false is currently required for all apps, and means that the app is only available to your account.

  • Avatar
    Jeff Tanner

    Hi James

    Sorry, but I was requesting if it is possible to get the value assigned (true or false) to manifest.json's key "private" from within a function() implementation in app.js?

    Thx

    • Jeff
  • Avatar
    James A. Rosen

    Can you describe your use case? I'm not against making that available to the app. We simply try to keep the API as uncluttered as possible.

  • Avatar
    Jeff Tanner

    As stated above, "private" is one way of stating if true then Lotus app is in Development mode, else live Production mode. Thereby

    1. For ajax calls, switching url between an integration API and production API
    2. For services.notify calls, turning on and off code tracing details

    -- Jeff

  • Avatar
    James A. Rosen

    "Private" wasn't meant to have the meaning you're giving it. It's supposed to mean "this app is only available to my account." It's possible that those two are the same for you: while it's in development, it's only available to your account; then, when you publish it, it becomes the "production" version.

    We've actually come up against this same use case ourselves in developing some of the apps you see in the app store. The problem is that once it's published, your development version would continue to act like a production version (e.g. high a production API on your servers).

    My suggestion is to use local variables in your app. I've posted a tip in the forum you might want to check out.

  • Avatar
    Jeff Tanner

    Thx, just curious

    • Jeff

Please sign in to leave a comment.

Powered by Zendesk