Skip to content

Instantly share code, notes, and snippets.

#include <ESP8266WiFi.h> // Include the Wi-Fi libraryconst
char* ssid = "SSID"; // The SSID (name) of network to connect
char* password = "PASSWORD"; // The password of the Wi-Fi
void setup() {
Serial.begin(115200); // Start the Serial communication
WiFi.begin(ssid, password); // Connect to the network
Serial.print("Connecting ");
while (WiFi.status() != WL_CONNECTED)
{ // Wait for the Wi-Fi to connect
#include <ESP8266WiFi.h> // WiFi Library
// The name of the Wi-Fi network to be created
const char *ssid = "ESP8266 Access Point";
const char *password = "password_here"; // The password to connect
void setup()
{
Serial.begin(115200);
delay(10);
Serial.println('\n');
WiFi.softAP(ssid, password); // Start the access point
@noob-master147
noob-master147 / OTAsetup.ino
Created May 11, 2020 13:34
NodeMCU setup file for Over The Air (OTA) uploads.
// This is Basic OTA file
#include <ESP8266WiFi.h>
#include <ESP8266mDNS.h>
#include <WiFiUdp.h>
#include <ArduinoOTA.h>
// Replace with your network credentialsconst
char* ssid = "YOUR_SSID";
const char* password = "YOUR_PASSWORD";
void setup()
{
@noob-master147
noob-master147 / payloadOTA.ino
Created May 11, 2020 13:37
OTA paload for blinking a LED
#include <ESP8266WiFi.h>
#include <ESP8266mDNS.h>
#include <WiFiUdp.h>
#include <ArduinoOTA.h>
// Replace with your network credentials
const char* ssid = "YOUR_SSID";
const char* password = "YOUR_PASSWORD";
const int ESP_BUILTIN_LED = 2;
void setup() {
Serial.begin(115200);
{
"authorization": {
"action": "microsoft.insights/metricAlerts/write",
"scope": "/subscriptions/700d83a9-185d-4c64-8e99-7a0dfd57cd43/resourceGroups/trial/providers/microsoft.insights/metricAlerts/CPU Alert"
},
"caller": "kaushik@spiked.sh",
"channels": "Operation",
"claims": {
"aud": "https://management.core.windows.net/",
"iss": "https://sts.windows.net/8a956349-749c-4548-ac72-effb0abc5351/",
@noob-master147
noob-master147 / Admin.js
Created June 20, 2020 14:15
Workbook Schema
const adminSchema = new mongoose.Schema({
role: {
type: String,
required: true,
default: "admin"
},
profilePicture: {
type: Buffer
},
{
"action": "update",
"actor": {
"email": "user-0436@example.com",
"id": "096370c8-f3ad-4e20-a309-fb4f06ec0a89"
},
"created_at": "2016-10-26T22:50:14Z",
"id": "d472a8bb-1a3c-4f78-aad1-995e6d0022ec",
"data": {
"archived_at": null,
{
"callback_url": "https://registry.hub.docker.com/u/svendowideit/testhook/hook/2141b5bi5i5b02bec211i4eeih0242eg11000a/",
"push_data": {
"images": [
"27d47432a69bca5f2700e4dff7de0388ed65f9d3fb1ec645e2bc24c223dc1cc3",
"51a9c7c1f8bb2fa19bcd09789a34e63f35abb80044bc10196e304f6634cc582c",
"..."
],
"pushed_at": 1.417566161e+09,
"pusher": "trustedbuilder",
@noob-master147
noob-master147 / apiFail.json
Last active July 1, 2020 04:56
Cronitor JSON Payloads
{
"id": "UH6G3i",
"rule": "request_triggered",
"monitor": "app testing endpoint",
"description": "Your healthcheck has failed.\n --> FAILED 15:12:17 UTC\n Request: GET https://app-workbook.herokuapp.com/\n Response: is not equal to 555"
}
{
event: "check.down",
check: {
url: "https://js.stripe.com/v3/",
status: 502,
down: true,
date: 1556506024291,
downtime: 1
},
pings: [