https://github.com/pedrosouza458/go-open-graph-scraper
Go-Open-Graph-Scraper is a go package to get metadata from websites easily, also returning formatted logos and names for any compatible website.
https://github.com/pedrosouza458/go-open-graph-scraper
go golang open-graph open-graph-protocol open-source package packages
Last synced: 12 months ago
JSON representation
Go-Open-Graph-Scraper is a go package to get metadata from websites easily, also returning formatted logos and names for any compatible website.
- Host: GitHub
- URL: https://github.com/pedrosouza458/go-open-graph-scraper
- Owner: pedrosouza458
- License: mit
- Created: 2024-08-20T21:46:35.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-09-02T16:12:40.000Z (over 1 year ago)
- Last Synced: 2025-04-14T01:37:10.232Z (about 1 year ago)
- Topics: go, golang, open-graph, open-graph-protocol, open-source, package, packages
- Language: Go
- Homepage:
- Size: 4.39 MB
- Stars: 5
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
README
## Golang Open Graph Scraper
This is a very simples Golang scraping that uses website OG (Open Graph) to get some informations like website name, page title, description and images, feel free to contribute forking this repo, the main goal is to use this package and my future project (that will also be open-source) and to study Golang, cause i know that packages like that already exists, but i wanna make my own.
### Run this code locally
```curl
git clone https://github.com/pedrosouza458/go-open-graph-scraper
```
```go
go mod tidy
```
```go
go run .
```
Now just type the website url in terminal, some sites will not display some informations.
## Example:
### Input
```
https://www.tabnews.com.br/marlon/ajuda-sujestao-de-conteudos-de-golang
```
### Output
```
Logo: https://i.imgur.com/O5OOa3s.png
Website name: tabnews
Image:https://www.tabnews.com.br/api/v1/contents/marlon/ajuda-sujestao-de-conteudos-de-golang/thumbnail
Page Name:[Ajuda] Sujestão de conteúdos de Golang · marlon
Page Description: Olá TabNews, estou querendo aprender Golang, vejo que é uma linguagem muito boa para trabalhar com DevOps e considerada muito rápida e fácil. Gostaria de pedir ajuda aos universitários co...
```