vantage.Invoice
Explore with Pulumi AI
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as vantage from "@pulumi/vantage";
const allInvoices = vantage.getInvoices({});
const demoInvoice = new vantage.Invoice("demoInvoice", {
accountToken: "acct_f87c7c90365bcdcd",
billingPeriodEnd: "2024-01-31",
billingPeriodStart: "2024-01-01",
});
import pulumi
import pulumi_vantage as vantage
all_invoices = vantage.get_invoices()
demo_invoice = vantage.Invoice("demoInvoice",
account_token="acct_f87c7c90365bcdcd",
billing_period_end="2024-01-31",
billing_period_start="2024-01-01")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/vantage/vantage"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := vantage.GetInvoices(ctx, &vantage.GetInvoicesArgs{}, nil)
if err != nil {
return err
}
_, err = vantage.NewInvoice(ctx, "demoInvoice", &vantage.InvoiceArgs{
AccountToken: pulumi.String("acct_f87c7c90365bcdcd"),
BillingPeriodEnd: pulumi.String("2024-01-31"),
BillingPeriodStart: pulumi.String("2024-01-01"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vantage = Pulumi.Vantage;
return await Deployment.RunAsync(() =>
{
var allInvoices = Vantage.GetInvoices.Invoke();
var demoInvoice = new Vantage.Invoice("demoInvoice", new()
{
AccountToken = "acct_f87c7c90365bcdcd",
BillingPeriodEnd = "2024-01-31",
BillingPeriodStart = "2024-01-01",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vantage.VantageFunctions;
import com.pulumi.vantage.inputs.GetInvoicesArgs;
import com.pulumi.vantage.Invoice;
import com.pulumi.vantage.InvoiceArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var allInvoices = VantageFunctions.getInvoices();
var demoInvoice = new Invoice("demoInvoice", InvoiceArgs.builder()
.accountToken("acct_f87c7c90365bcdcd")
.billingPeriodEnd("2024-01-31")
.billingPeriodStart("2024-01-01")
.build());
}
}
resources:
demoInvoice:
type: vantage:Invoice
properties:
accountToken: acct_f87c7c90365bcdcd
billingPeriodEnd: 2024-01-31
billingPeriodStart: 2024-01-01
variables:
allInvoices:
fn::invoke:
function: vantage:getInvoices
arguments: {}
Create Invoice Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Invoice(name: string, args: InvoiceArgs, opts?: CustomResourceOptions);
@overload
def Invoice(resource_name: str,
args: InvoiceArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Invoice(resource_name: str,
opts: Optional[ResourceOptions] = None,
account_token: Optional[str] = None,
billing_period_end: Optional[str] = None,
billing_period_start: Optional[str] = None)
func NewInvoice(ctx *Context, name string, args InvoiceArgs, opts ...ResourceOption) (*Invoice, error)
public Invoice(string name, InvoiceArgs args, CustomResourceOptions? opts = null)
public Invoice(String name, InvoiceArgs args)
public Invoice(String name, InvoiceArgs args, CustomResourceOptions options)
type: vantage:Invoice
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args InvoiceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args InvoiceArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args InvoiceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args InvoiceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args InvoiceArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var invoiceResource = new Vantage.Invoice("invoiceResource", new()
{
AccountToken = "string",
BillingPeriodEnd = "string",
BillingPeriodStart = "string",
});
example, err := vantage.NewInvoice(ctx, "invoiceResource", &vantage.InvoiceArgs{
AccountToken: pulumi.String("string"),
BillingPeriodEnd: pulumi.String("string"),
BillingPeriodStart: pulumi.String("string"),
})
var invoiceResource = new Invoice("invoiceResource", InvoiceArgs.builder()
.accountToken("string")
.billingPeriodEnd("string")
.billingPeriodStart("string")
.build());
invoice_resource = vantage.Invoice("invoiceResource",
account_token="string",
billing_period_end="string",
billing_period_start="string")
const invoiceResource = new vantage.Invoice("invoiceResource", {
accountToken: "string",
billingPeriodEnd: "string",
billingPeriodStart: "string",
});
type: vantage:Invoice
properties:
accountToken: string
billingPeriodEnd: string
billingPeriodStart: string
Invoice Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Invoice resource accepts the following input properties:
- Account
Token string - Token of the managed account to invoice
- Billing
Period stringEnd - End date of billing period (YYYY-MM-DD)
- Billing
Period stringStart - Start date of billing period (YYYY-MM-DD)
- Account
Token string - Token of the managed account to invoice
- Billing
Period stringEnd - End date of billing period (YYYY-MM-DD)
- Billing
Period stringStart - Start date of billing period (YYYY-MM-DD)
- account
Token String - Token of the managed account to invoice
- billing
Period StringEnd - End date of billing period (YYYY-MM-DD)
- billing
Period StringStart - Start date of billing period (YYYY-MM-DD)
- account
Token string - Token of the managed account to invoice
- billing
Period stringEnd - End date of billing period (YYYY-MM-DD)
- billing
Period stringStart - Start date of billing period (YYYY-MM-DD)
- account_
token str - Token of the managed account to invoice
- billing_
period_ strend - End date of billing period (YYYY-MM-DD)
- billing_
period_ strstart - Start date of billing period (YYYY-MM-DD)
- account
Token String - Token of the managed account to invoice
- billing
Period StringEnd - End date of billing period (YYYY-MM-DD)
- billing
Period StringStart - Start date of billing period (YYYY-MM-DD)
Outputs
All input properties are implicitly available as output properties. Additionally, the Invoice resource produces the following output properties:
- Account
Name string - Name of the managed account this invoice belongs to
- Created
At string - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- Id string
- The provider-assigned unique ID for this managed resource.
- Invoice
Number string - Sequential invoice number for the MSP account
- Msp
Account stringToken - Token of the MSP account that owns this invoice
- Status string
- Current status of the invoice
- Token string
- The token of the invoice
- Total string
- Total amount for the invoice period
- Updated
At string - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
- Account
Name string - Name of the managed account this invoice belongs to
- Created
At string - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- Id string
- The provider-assigned unique ID for this managed resource.
- Invoice
Number string - Sequential invoice number for the MSP account
- Msp
Account stringToken - Token of the MSP account that owns this invoice
- Status string
- Current status of the invoice
- Token string
- The token of the invoice
- Total string
- Total amount for the invoice period
- Updated
At string - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
- account
Name String - Name of the managed account this invoice belongs to
- created
At String - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- id String
- The provider-assigned unique ID for this managed resource.
- invoice
Number String - Sequential invoice number for the MSP account
- msp
Account StringToken - Token of the MSP account that owns this invoice
- status String
- Current status of the invoice
- token String
- The token of the invoice
- total String
- Total amount for the invoice period
- updated
At String - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
- account
Name string - Name of the managed account this invoice belongs to
- created
At string - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- id string
- The provider-assigned unique ID for this managed resource.
- invoice
Number string - Sequential invoice number for the MSP account
- msp
Account stringToken - Token of the MSP account that owns this invoice
- status string
- Current status of the invoice
- token string
- The token of the invoice
- total string
- Total amount for the invoice period
- updated
At string - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
- account_
name str - Name of the managed account this invoice belongs to
- created_
at str - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- id str
- The provider-assigned unique ID for this managed resource.
- invoice_
number str - Sequential invoice number for the MSP account
- msp_
account_ strtoken - Token of the MSP account that owns this invoice
- status str
- Current status of the invoice
- token str
- The token of the invoice
- total str
- Total amount for the invoice period
- updated_
at str - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
- account
Name String - Name of the managed account this invoice belongs to
- created
At String - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- id String
- The provider-assigned unique ID for this managed resource.
- invoice
Number String - Sequential invoice number for the MSP account
- msp
Account StringToken - Token of the MSP account that owns this invoice
- status String
- Current status of the invoice
- token String
- The token of the invoice
- total String
- Total amount for the invoice period
- updated
At String - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
Look up Existing Invoice Resource
Get an existing Invoice resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: InvoiceState, opts?: CustomResourceOptions): Invoice
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
account_name: Optional[str] = None,
account_token: Optional[str] = None,
billing_period_end: Optional[str] = None,
billing_period_start: Optional[str] = None,
created_at: Optional[str] = None,
invoice_number: Optional[str] = None,
msp_account_token: Optional[str] = None,
status: Optional[str] = None,
token: Optional[str] = None,
total: Optional[str] = None,
updated_at: Optional[str] = None) -> Invoice
func GetInvoice(ctx *Context, name string, id IDInput, state *InvoiceState, opts ...ResourceOption) (*Invoice, error)
public static Invoice Get(string name, Input<string> id, InvoiceState? state, CustomResourceOptions? opts = null)
public static Invoice get(String name, Output<String> id, InvoiceState state, CustomResourceOptions options)
resources: _: type: vantage:Invoice get: id: ${id}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Account
Name string - Name of the managed account this invoice belongs to
- Account
Token string - Token of the managed account to invoice
- Billing
Period stringEnd - End date of billing period (YYYY-MM-DD)
- Billing
Period stringStart - Start date of billing period (YYYY-MM-DD)
- Created
At string - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- Invoice
Number string - Sequential invoice number for the MSP account
- Msp
Account stringToken - Token of the MSP account that owns this invoice
- Status string
- Current status of the invoice
- Token string
- The token of the invoice
- Total string
- Total amount for the invoice period
- Updated
At string - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
- Account
Name string - Name of the managed account this invoice belongs to
- Account
Token string - Token of the managed account to invoice
- Billing
Period stringEnd - End date of billing period (YYYY-MM-DD)
- Billing
Period stringStart - Start date of billing period (YYYY-MM-DD)
- Created
At string - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- Invoice
Number string - Sequential invoice number for the MSP account
- Msp
Account stringToken - Token of the MSP account that owns this invoice
- Status string
- Current status of the invoice
- Token string
- The token of the invoice
- Total string
- Total amount for the invoice period
- Updated
At string - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
- account
Name String - Name of the managed account this invoice belongs to
- account
Token String - Token of the managed account to invoice
- billing
Period StringEnd - End date of billing period (YYYY-MM-DD)
- billing
Period StringStart - Start date of billing period (YYYY-MM-DD)
- created
At String - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- invoice
Number String - Sequential invoice number for the MSP account
- msp
Account StringToken - Token of the MSP account that owns this invoice
- status String
- Current status of the invoice
- token String
- The token of the invoice
- total String
- Total amount for the invoice period
- updated
At String - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
- account
Name string - Name of the managed account this invoice belongs to
- account
Token string - Token of the managed account to invoice
- billing
Period stringEnd - End date of billing period (YYYY-MM-DD)
- billing
Period stringStart - Start date of billing period (YYYY-MM-DD)
- created
At string - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- invoice
Number string - Sequential invoice number for the MSP account
- msp
Account stringToken - Token of the MSP account that owns this invoice
- status string
- Current status of the invoice
- token string
- The token of the invoice
- total string
- Total amount for the invoice period
- updated
At string - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
- account_
name str - Name of the managed account this invoice belongs to
- account_
token str - Token of the managed account to invoice
- billing_
period_ strend - End date of billing period (YYYY-MM-DD)
- billing_
period_ strstart - Start date of billing period (YYYY-MM-DD)
- created_
at str - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- invoice_
number str - Sequential invoice number for the MSP account
- msp_
account_ strtoken - Token of the MSP account that owns this invoice
- status str
- Current status of the invoice
- token str
- The token of the invoice
- total str
- Total amount for the invoice period
- updated_
at str - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
- account
Name String - Name of the managed account this invoice belongs to
- account
Token String - Token of the managed account to invoice
- billing
Period StringEnd - End date of billing period (YYYY-MM-DD)
- billing
Period StringStart - Start date of billing period (YYYY-MM-DD)
- created
At String - The date and time, in UTC, the invoice was created. ISO 8601 formatted.
- invoice
Number String - Sequential invoice number for the MSP account
- msp
Account StringToken - Token of the MSP account that owns this invoice
- status String
- Current status of the invoice
- token String
- The token of the invoice
- total String
- Total amount for the invoice period
- updated
At String - The date and time, in UTC, the invoice was last updated. ISO 8601 formatted.
Package Details
- Repository
- vantage vantage-sh/terraform-provider-vantage
- License
- Notes
- This Pulumi package is based on the
vantage
Terraform Provider.