Skip to content

Commit

Permalink
Improve table docs (#11)
Browse files Browse the repository at this point in the history
  • Loading branch information
misraved authored Dec 12, 2023
1 parent 2b19485 commit aa61748
Show file tree
Hide file tree
Showing 12 changed files with 1,461 additions and 92 deletions.
12 changes: 12 additions & 0 deletions .github/workflows/steampipe-anywhere.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: Release Steampipe Anywhere Components

on:
push:
tags:
- 'v*'


jobs:
anywhere_publish_workflow:
uses: turbot/steampipe-workflows/.github/workflows/steampipe-anywhere.yml@main
secrets: inherit
24 changes: 21 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,18 @@ from
+-------------+---------------------------+----------+--------+----------+----------+----------------------+
```

## Engines

This plugin is available for the following engines:

| Engine | Description
|---------------|------------------------------------------
| [Steampipe](https://steampipe.io/docs) | The Steampipe CLI exposes APIs and services as a high-performance relational database, giving you the ability to write SQL-based queries to explore dynamic data. Mods extend Steampipe's capabilities with dashboards, reports, and controls built with simple HCL. The Steampipe CLI is a turnkey solution that includes its own Postgres database, plugin management, and mod support.
| [Postgres FDW](https://steampipe.io/docs/steampipe_postgres/overview) | Steampipe Postgres FDWs are native Postgres Foreign Data Wrappers that translate APIs to foreign tables. Unlike Steampipe CLI, which ships with its own Postgres server instance, the Steampipe Postgres FDWs can be installed in any supported Postgres database version.
| [SQLite Extension](https://steampipe.io/docs//steampipe_sqlite/overview) | Steampipe SQLite Extensions provide SQLite virtual tables that translate your queries into API calls, transparently fetching information from your API or service as you request it.
| [Export](https://steampipe.io/docs/steampipe_export/overview) | Steampipe Plugin Exporters provide a flexible mechanism for exporting information from cloud services and APIs. Each exporter is a stand-alone binary that allows you to extract data using Steampipe plugins without a database.
| [Turbot Pipes](https://turbot.com/pipes/docs) | Turbot Pipes is the only intelligence, automation & security platform built specifically for DevOps. Pipes provide hosted Steampipe database instances, shared dashboards, snapshots, and more.

## Developing

Prerequisites:
Expand Down Expand Up @@ -106,11 +118,17 @@ Further reading:
- [Writing plugins](https://steampipe.io/docs/develop/writing-plugins)
- [Writing your first table](https://steampipe.io/docs/develop/writing-your-first-table)

## Contributing
## Open Source & Contributing

This repository is published under the [Apache 2.0](https://www.apache.org/licenses/LICENSE-2.0) (source code) and [CC BY-NC-ND](https://creativecommons.org/licenses/by-nc-nd/2.0/) (docs) licenses. Please see our [code of conduct](https://github.com/turbot/.github/blob/main/CODE_OF_CONDUCT.md). We look forward to collaborating with you!

[Steampipe](https://steampipe.io) is a product produced from this open source software, exclusively by [Turbot HQ, Inc](https://turbot.com). It is distributed under our commercial terms. Others are allowed to make their own distribution of the software, but cannot use any of the Turbot trademarks, cloud services, etc. You can learn more in our [Open Source FAQ](https://turbot.com/open-source).

## Get Involved

Please see the [contribution guidelines](https://github.com/turbot/steampipe/blob/main/CONTRIBUTING.md) and our [code of conduct](https://github.com/turbot/steampipe/blob/main/CODE_OF_CONDUCT.md). All contributions are subject to the [Apache 2.0 open source license](https://github.com/turbot/steampipe-plugin-hubspot/blob/main/LICENSE).
**[Join #steampipe on Slack →](https://turbot.com/community/join)**

`help wanted` issues:
Want to help but don't know where to start? Pick up one of the `help wanted` issues:

- [Steampipe](https://github.com/turbot/steampipe/labels/help%20wanted)
- [HubSpot Plugin](https://github.com/turbot/steampipe-plugin-hubspot/labels/help%20wanted)
402 changes: 402 additions & 0 deletions docs/LICENSE

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,16 @@ short_name: "hubspot"
description: "Steampipe plugin to query contacts, deals, tickets and more from HubSpot."
og_description: "Query HubSpot with SQL! Open source CLI. No DB required."
og_image: "/images/plugins/turbot/hubspot-social-graphic.png"
engines: ["steampipe", "sqlite", "postgres", "export"]
---

# HubSpot + Steampipe

[Steampipe](https://steampipe.io) is an open-source zero-ETL engine to instantly query cloud APIs using SQL.

[HubSpot](https://www.hubspot.com/) is a CRM platform with all the software, integrations, and resources you need to connect marketing, sales, content management, and customer service. Each product in the platform is powerful on its own, but the real magic happens when you use them together.

[Steampipe](https://steampipe.io) is an open source CLI to instantly query cloud APIs using SQL.


List your HubSpot deals:

Expand Down Expand Up @@ -85,7 +88,4 @@ Alternatively, you can also use the standard HubSpot environment variable to obt
export HUBSPOT_PRIVATE_APP_TOKEN=pat-na1-70271006-11d8-4a5d-9169-b12f4327e5b
```

## Get involved

- Open source: https://github.com/turbot/steampipe-plugin-hubspot
- Community: [Join #steampipe on Slack →](https://turbot.com/community/join)
187 changes: 165 additions & 22 deletions docs/tables/hubspot_blog_post.md
Original file line number Diff line number Diff line change
@@ -1,26 +1,36 @@
# Table: hubspot_blog_post
---
title: "Steampipe Table: hubspot_blog_post - Query HubSpot Blog Posts using SQL"
description: "Allows users to query Blog Posts in HubSpot, providing insights into the content, performance, and metadata of each post."
---

A HubSpot blog post is an article or piece of content that you create and publish on the HubSpot blogging platform. It allows you to share information, insights, and updates with your audience. HubSpot's blogging tools provide a user-friendly interface for writing, editing, and formatting your blog posts.
# Table: hubspot_blog_post - Query HubSpot Blog Posts using SQL

When creating a HubSpot blog post, you can:
HubSpot's Blog Post feature is a part of its broader content management system, allowing users to create, manage, and analyze blog content. It offers a platform for publishing rich, SEO-optimized content to engage audiences and drive traffic. Blog Posts in HubSpot are an essential tool for inbound marketing strategies, offering features like scheduling, analytics, and integrated CTAs.

- Write and format your content: Use the text editor to write your blog post, format text, add headings, apply styles, and insert images or media.
## Table Usage Guide

- Optimize for search engines: HubSpot provides SEO (search engine optimization) tools to optimize your blog post for better visibility in search engine results. You can add meta titles, descriptions, and keywords, and HubSpot offers recommendations to improve your SEO.

- Categorize and tag your blog post: Organize your blog posts into categories and assign relevant tags to make it easier for readers to find related content on your blog.

- Schedule or publish your blog post: Choose a publishing date and time to schedule your blog post in advance or publish it immediately.

- Analyze performance: HubSpot's analytics tools provide insights into your blog post's performance, including views, engagement, and conversion metrics.

HubSpot's blogging platform offers additional features like social sharing, commenting, and integrations with other marketing tools. It enables you to create and manage your blog content within the HubSpot ecosystem, integrating it with your broader marketing strategy.
The `hubspot_blog_post` table provides insights into the blog posts within HubSpot's content management system. As a content manager or marketing analyst, explore post-specific details through this table, including content, performance, and associated metadata. Utilize it to uncover information about posts, such as their SEO performance, engagement metrics, and the effectiveness of integrated CTAs.

## Examples

### Basic info
Explore the status and details of blog posts in your Hubspot account. This query can help you understand the distribution of your content, identify who's producing it, and when it's being published.

```sql+postgres
select
id,
title,
slug,
campaign,
state,
archived,
author_name,
publish_date
from
hubspot_blog_post;
```

```sql
```sql+sqlite
select
id,
title,
Expand All @@ -35,8 +45,9 @@ from
```

### List all published blog posts
Explore all the blog posts that are currently live to understand the range of topics and authors contributing to your content. This can help in assessing the diversity of your content and identifying any gaps that need to be filled.

```sql
```sql+postgres
select
id,
title,
Expand All @@ -52,9 +63,26 @@ where
currently_published;
```

```sql+sqlite
select
id,
title,
slug,
campaign,
state,
archived,
author_name,
publish_date
from
hubspot_blog_post
where
currently_published = 1;
```

### List all archived blog posts
Discover the segments that contain all your archived blog posts. This aids in understanding the range and history of content that is no longer actively promoted but may still hold value.

```sql
```sql+postgres
select
id,
title,
Expand All @@ -70,9 +98,42 @@ where
archived;
```

```sql+sqlite
select
id,
title,
slug,
campaign,
state,
archived,
author_name,
publish_date
from
hubspot_blog_post
where
archived = 1;
```

### List blog posts created by a specific author
Explore which blog posts have been crafted by a specific author to gain insights into their productivity and content focus. This can be beneficial for content management and planning, allowing you to identify popular topics and authors.

```sql+postgres
select
id,
title,
slug,
campaign,
state,
archived,
author_name,
publish_date
from
hubspot_blog_post
where
author_name = 'John Doe';
```

```sql
```sql+sqlite
select
id,
title,
Expand All @@ -89,8 +150,9 @@ where
```

### Get blog posts created by a specific owner
Explore blog posts authored by a specific individual to understand their contribution and publishing pattern. This can be particularly useful in content management scenarios, where tracking the work of specific authors is crucial for editorial oversight and planning.

```sql
```sql+postgres
select
p.id,
p.title,
Expand All @@ -107,9 +169,42 @@ where
and o.first_name = 'john';
```

```sql+sqlite
select
p.id,
p.title,
slug,
campaign,
state,
author_name,
publish_date
from
hubspot_blog_post as p,
hubspot_owner as o
where
cast(created_by_id as integer) = user_id
and o.first_name = 'john';
```

### List blog posts in a specific category
Discover the segments that fall under a particular category within your blog posts. This can help you understand the distribution of your content and strategize your future posts accordingly.

```sql+postgres
select
id,
title,
slug,
campaign,
state,
author_name,
publish_date
from
hubspot_blog_post
where
category_id = 123;
```

```sql
```sql+sqlite
select
id,
title,
Expand All @@ -125,8 +220,9 @@ where
```

### List blog posts that have a featured image
Explore the blog posts that have a featured image to understand the impact of visual content on reader engagement. This can be useful in enhancing your content strategy by focusing on posts that are more likely to attract and retain readers.

```sql
```sql+postgres
select
id,
title,
Expand All @@ -141,9 +237,40 @@ where
use_featured_image;
```

```sql+sqlite
select
id,
title,
slug,
campaign,
state,
author_name,
publish_date
from
hubspot_blog_post
where
use_featured_image = 1;
```

### List blog posts published in a specific campaign
Discover the segments that include blog posts published under a specific campaign. This can be useful for marketers aiming to analyze the performance of individual campaigns and their related content.

```sql+postgres
select
id,
title,
slug,
campaign,
state,
author_name,
publish_date
from
hubspot_blog_post
where
campaign = 'CAMPAIGN123';
```

```sql
```sql+sqlite
select
id,
title,
Expand All @@ -159,8 +286,9 @@ where
```

### Get blog posts that have public access rules enabled
Discover the segments that have public access rules enabled, allowing you to pinpoint blog posts that are accessible to the general public. This can be useful in assessing the visibility and reach of your content.

```sql
```sql+postgres
select
id,
title,
Expand All @@ -174,3 +302,18 @@ from
where
public_access_rules_enabled;
```

```sql+sqlite
select
id,
title,
slug,
campaign,
state,
author_name,
publish_date
from
hubspot_blog_post
where
public_access_rules_enabled = 1;
```
Loading

0 comments on commit aa61748

Please sign in to comment.