Skip to content

Instantly share code, notes, and snippets.

View alexandrebl's full-sized avatar
🛰️
Working from space

ABrandaoL alexandrebl

🛰️
Working from space
View GitHub Profile
@alexandrebl
alexandrebl / Pine_Script_5_Mini_Reference.md
Created March 2, 2025 15:27 — forked from kaigouthro/Pine_Script_5_Mini_Reference.md
A minimal reference to pine script v5

Pine Script Mini-Reference

This document provides a concise reference for Pine Script, a programming language specifically designed for trading strategies and indicators within TradingView.

Operators

Arithmetic Operators

Operator Description
@alexandrebl
alexandrebl / readMessagensFromTelegram.py
Last active August 14, 2024 23:54
Read MEssages from Telegram using Python
import datetime, os
from telethon import TelegramClient, events
from telethon.sync import TelegramClient
# Substitua esses valores pelos seus próprios
api_id = 'API_ID'
api_hash = 'API_HASH'
phone_number = 'PHONE_NUMBER'
client = TelegramClient('session_name', api_id, api_hash)
@alexandrebl
alexandrebl / telegramReadMessages.py
Created August 14, 2024 22:59
Telegram Read Message em Python
from telethon import TelegramClient, events
from telethon.sync import TelegramClient
# Substitua esses valores pelos seus próprios
api_id = 'APIID'
api_hash = 'API_HASH'
phone_number = 'PHONE NUMBER'
client = TelegramClient('session_name', api_id, api_hash)
@alexandrebl
alexandrebl / telegram.bot.cs
Created August 14, 2024 19:49
Telegram Bot CSharp C# .Net
using Telegram.Bot;
using Telegram.Bot.Exceptions;
using Telegram.Bot.Polling;
using Telegram.Bot.Types;
using Telegram.Bot.Types.Enums;
namespace ConsoleApp1;
class Program
{
@alexandrebl
alexandrebl / binance.webhook.buy.json
Created June 23, 2024 23:07
Binance Webhook JSON Payload Buy
{
"symbol": "ETHUSDC.P",
"side": "BUY",
"qty": "30",
"price": "market",
"signalId": "0a7f4106-b14b-4ae3-a0b1-45ad7f77d1b2",
"uid": "07ef275a-f4df-4071-b6d0-77986d5402f7"
}
@alexandrebl
alexandrebl / binance.webhook.sell.json
Created June 23, 2024 23:06
Binance Webhook JSON Payload Sell
{
"symbol": "ETHUSDC.P",
"side": "SELL",
"qty": "30",
"price": "market",
"signalId": "33a9e79a-090e-42e4-9548-e46f17da8d9a",
"uid": "0b1f307d-3ca7-431c-8060-301fd58144e8"
}
//SPDX-License-Identifier: MIT
pragma solidity 0.8.14;
contract MyContract {
string public ourString = "Hello World";
}
@alexandrebl
alexandrebl / JurosCompostosExcel.txt
Created June 24, 2022 16:14
Juros Compostos Excel
=VF(B3;B4;B2;B1;)*-1
@alexandrebl
alexandrebl / ClienteUsingDependencyInjectionNamedHttpClientFactory.cs
Created April 22, 2022 14:31
Cliente Using Dependency Injection Named Http Client Factory
public class NamedClientModel : PageModel
{
private readonly IHttpClientFactory _httpClientFactory;
public NamedClientModel(IHttpClientFactory httpClientFactory) =>
_httpClientFactory = httpClientFactory;
public IEnumerable<GitHubBranch>? GitHubBranches { get; set; }
public async Task OnGet()
@alexandrebl
alexandrebl / DINamedHttpClientFactory.cs
Created April 22, 2022 14:30
Dependency Injection Named Http Client Factory
builder.Services.AddHttpClient("GitHub", httpClient =>
{
httpClient.BaseAddress = new Uri("https://api.github.com/");
// using Microsoft.Net.Http.Headers;
// The GitHub API requires two headers.
httpClient.DefaultRequestHeaders.Add(
HeaderNames.Accept, "application/vnd.github.v3+json");
httpClient.DefaultRequestHeaders.Add(
HeaderNames.UserAgent, "HttpRequestsSample");