Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request for Contribution Guide #112

Open
6 tasks
oxenprogrammer opened this issue Sep 7, 2023 · 3 comments
Open
6 tasks

Request for Contribution Guide #112

oxenprogrammer opened this issue Sep 7, 2023 · 3 comments

Comments

@oxenprogrammer
Copy link

Problem

Contributors to the AfricaIsTalking API would benefit from having clear and comprehensive guidelines on how to contribute effectively to the project. Currently, there is no contribution guide available, making it challenging for newcomers to get started and for existing contributors to follow best practices consistently.

Solution

We propose creating a Contribution Guide for the AfricaIsTalking API. This guide will provide step-by-step instructions and best practices for contributing to the project. It should cover topics such as:

  • Setting up the development environment
  • How to submit bug reports and feature requests
  • Guidelines for writing and formatting code
  • The pull request process
  • Code review expectations
  • Testing and quality assurance procedures
  • Licensing and code of conduct

Benefits

A well-structured contribution guide will have several advantages:

  1. Onboarding New Contributors: Newcomers will find it easier to understand the project's workflow and coding standards, reducing the barrier to entry.

  2. Consistency: Contributors will follow a consistent process when submitting contributions, making it easier for maintainers to review and merge changes.

  3. Improved Code Quality: By providing guidelines for writing code and running tests, we can ensure that contributions meet the project's quality standards.

  4. Community Growth: A clear contribution guide can attract more contributors, fostering a healthy and active open-source community.

Acceptance Criteria:

  • Create a new file named CONTRIBUTING.md in the project repository.
  • Document the contribution process, coding standards, and testing procedures in the CONTRIBUTING.md file.
  • Include information on how to report issues and request features.
  • Mention the project's code of conduct and licensing.
  • Ensure that the guide is clear, concise, and easy to follow.
  • Share the contribution guide with the project's community through relevant channels.

Additional Information:

We believe that providing a contribution guide will greatly enhance the development experience for all contributors and help the AfricaIsTalking API project thrive. Your input and contributions to creating this guide are highly appreciated.

Please feel free to discuss and offer suggestions related to this issue. Thank you for your support and dedication to the project!

@oxenprogrammer
Copy link
Author

@DaggieBlanqx Is anything going to get done here?

@kievo23
Copy link

kievo23 commented Dec 20, 2023

### Airtime
Am having issues on following the docs vs what the API is giving as feedback. The node js package which am using is also giving me a hard time since am using ES6. I would appreciate if the docs and packages can be updated as some of the dependencies are deprecated.

For someone using ES6. you can use the following code. You will need axios library, very awesome library in my opinion
Say you have name the code below as Africastalking.js

`

import axios from "axios";

const AirtimeInstance = async () => {

return axios.create({
baseURL: 'https://api.africastalking.com',
headers: {
'Accept': 'application/json',
'Content-Type': 'application/x-www-form-urlencoded',
'apiKey': ${process.env.AfricasTalkingApiKey}
},
data : {'username' : 'bambaCredo'}
})
}

const sendAirtime = async (phone,amount) => {
let request = await AirtimeInstance();
return request.post('version1/airtime/send', {
username : ${process.env.AfricasTalkingUsername},
maxNumRetry: 2,
recipients : JSON.stringify([{phoneNumber: phone, amount: KES ${amount} }])
});
}

export default sendAirtime`

Then on calling the code, do

`import sendAirtime from "./Africastalking.js"

let result = await sendAirtime("+254105730XYZ","7");
console.log(result.data)`

Hope this helps someone. Its simple though

@DaggieBlanqx
Copy link
Member

@oxenprogrammer the issue on callTo parameter only initiating call to last number in array was resolved in v0.6.3. Kindly use the latest version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants