Coder Social home page Coder Social logo

cronofy-csharp-sample-app's Introduction

Cronofy C# Sample Application

Prerequisites

A Git Tool

We would recommend downloading and using the Git Bash tool, which you can find here.

A cloned version of this repository

For help in cloning this repository please see this article.

A .NET IDE

We would recommend using Xamarin Studio to build and run this project on mac and Visual Studio for Windows.

Set-up

Create a Cronofy application

To use the Cronofy C# Sample App you need to create a Cronofy application. To do this, create a free developer account, click "Create New App" in the left-hand navigation and create an application.

Once you've created your application you will need to set the cronofy_client_id and cronofy_client_secret in the application's Web.config file.

An example of how to do this:

<configuration>
  ...
  <appSettings>
    <add key="cronofy_client_id" value="{{cronofy_client_id}}" />
    <add key="cronofy_client_secret" value="{{cronofy_client_secret}}" />
  </appSettings>
</configuration>

Setting up a Remote URL

In order to test Push Notification callbacks and Enterprise Connect user authentications your application will need to be reachable by the internet.

To do this we would recommend using ngrok to create a URL that is accessible by the Cronofy API.

Once you have ngrok installed you can initialise it for your application by using the following line in your terminal:

ngrok http -host-header=localhost localhost:8080 (Replace localhost:8080 with localhost:[port number] where appropriate)

Your terminal will then display a URL in the format http://[unique identifier].ngrok.io. You will need to set the domain variable in the application's Web.config in order to test these remote features for example.

<configuration>
  ...
  <appSettings>
    ...
    <add key="domain" value="http://examplecallback.ngrok.io" />
  </appSettings>
</configuration>

cronofy-csharp-sample-app's People

Contributors

haziba avatar nevett avatar stephenbinns avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

cronofy-csharp-sample-app's Issues

Prompt user to use ngrok on failed callback setup

Developers are getting confused with the domain app key, we should make this more clear to them we can make this better by doing:

  1. Rename app-key name to something more sensible
  2. Handle errors on callback setup to prompt to install and use ngrok filling in fields for local port and generating them the setting to go into web.config along with the command for ngrok

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.