Using a 3rd party node-js library in scriptr.io
  • Did not see a forum for scriptr.io so figured I would post the question here rather than send an email so everyone benefits.

    How do I use someone else's github library in my own scriptr.io script? 

    I am working on creating a Slack chatBot and want to program the logic in scriptr.io.   This is all new to me so I have to learn about web hooks and I'm using scriptr.io instead of apstrata workbench for server side scripts for the first time.

    Slack recommends using this botkit to access their api. 
    https://github.com/howdyai/botkit

    The script.io docs mention modules and connecting to github.  In this case I want to use someone else's githiub repository.  Not my own.

    Thanks,
    Pete 


  • Hi Pete,

    There is an article on scriptr.io's blog that describes how to do this.

    Note though that scriptr.io is not node.js based and therefore, your library might not work.

    Karim
  • Thanks for the response.  I looked at the article on the blog.  It explains how to add scriptr.io' github library not someone else's.  Other than using it to find open source libraries I am not very familar with using github to store my own source code.  I did create the access token but I am not sure values I should put in settings for the repository owner, name, branch and path.  
  • Hi Pete,

    Retrieving source code from any Github repository into a scriptr.io account will be supported soon but cannot be done currently. 

    The only repositories you have access to from scriptr.io are your own and scriptrdotio. I suggest that you import the code you are interested in into your Github repository then import the latter to your scriptr.io account using the procedure described in scriptr.io's blog

  • I cloned the botkit and added it to my own repository.  I then changed the github settings in scriptr.io.  I am no longer getting the github connection error but I am not seeing any files appearing on the left hand side in the synchronize tab.   


Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!