# sourceapi

> Source Code API for https://sourcecode.glitch.me

Latest version **0.0.4** (published 2018-04-30) · MIT license · 0 weekly downloads

## Install

```sh
npm install sourceapi
pnpm add sourceapi
yarn add sourceapi
bun add sourceapi
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.4 |
| Published | 2018-04-30 |
| First published | 2018-04-30 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 25.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | truexpixels |
| Maintainers | truexpixels |
| Keywords | API, Source, Code |

## Links

- npm: https://www.npmjs.com/package/sourceapi
- npm.io page: https://npm.io/package/sourceapi

## Dependencies (1)

- [snekfetch](https://npm.io/package/snekfetch.md) ^4.0.0

## Alternatives

- [flatbuffers](https://npm.io/package/flatbuffers.md) — 6.0M weekly downloads
- [jwt-simple](https://npm.io/package/jwt-simple.md) — 259.5K weekly downloads
- [@exodus/patch-broken-hermes-typed-arrays](https://npm.io/package/@exodus/patch-broken-hermes-typed-arrays.md) — 28.5K weekly downloads
- [@native-to-anchor/buffer-layout](https://npm.io/package/@native-to-anchor/buffer-layout.md) — 12.2K weekly downloads
- [binary-parser-encoder](https://npm.io/package/binary-parser-encoder.md) — 5.3K weekly downloads

## Recent versions

- 0.0.4 (latest) — 2018-04-30
- 0.0.3 — 2018-04-30
- 0.0.2 — 2018-04-30
- 0.0.1 — 2018-04-30

## README

Source Code API
===

#### NOTE: This is an alpha build while the API gets reworked, supports ID's & `all`

**Website: [https://sourcecode.glitch.me](https://sourcecode.glitch.me)**

**Note:**
- `<data>.packagesUsed` are actually `tags`
- `<data>.views` aren't counted
- `<data>.rating` may return an array

**Example:**
```js
let sc = require('sourceapi');

sc('1363896474854890').then(i => {
  
  console.log(i);
  /* ->
  
  { username: '[HypeSquad] ricegrains#0911',
  title: 'Weather command',
  difficulty: 'Easy/Medium',
  packagesUsed: 'weather-js, discord.js',
  code: 'const Discord = require(\'discord.js\');\nconst weather = require(\'weather-js\');\n\nmodule.exports.run = (client, message, args) => {\n  weather.find({search: args.join(" "), degreeType: \'C\'}, function(err, result) {\n      if (err) message.channel.send(err);\n      if (result === undefined || result.length === 0) {\n          message.channel.send(\'**Please enter a location!**\')\n          return;\n      }\n      var current = result[0].current;\n      var location = result[0].location;\n      const embed = new Discord.RichEmbed()\n          .setDescription(`**${current.skytext}**`)\n          .setAuthor(`Weather for ${current.observationpoint}`)\n          .setThumbnail(current.imageUrl)\n          .setColor(0x00AE86)\n          .addField(\'Timezone\',`UTC${location.timezone}`, true)\n          .addField(\'Degree Type\',location.degreetype, true)\n          .addField(\'Temperature\',`${current.temperature} Degrees`, true)\n          .addField(\'Feels Like\', `${current.feelslike} Degrees`, true)\n          .addField(\'Winds\',current.winddisplay, true)\n          .addField(\'Humidity\', `${current.humidity}%`, true)\n          message.channel.send({embed});\n  })\n}',
  desc: '',
  key: '1363896474854890',
  approved: true,
  views: 0,
  rating: 0 }
  
  */
  
});
```

---
_Source: https://npm.io/package/sourceapi · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
